Search code examples
postgresqlpostgis

How to set value in selected columns?


I use this code for select columns

select cities.name,cities.geom,cities.area
from cities,delivery
where ST_Intersects(delivery.geom,cities.geom)

It return this result

It return this result How i can set value "true" for "area" column? I am not familiar with the language - tell me how to set the values? Biggest thx!


Solution

  • update cities set area = 'true'
    from delivery
    where ST_Intersects(delivery.geom,cities.geom);