Tag Info

Hot answers tagged

6

Ironically, the fastest way to find the set of things not within other things is to do a full join that finds the contained things, but using a LEFT JOIN, so the un-matched things are hanging about to be found, thus: SELECT pts.* FROM pts LEFT JOIN polys ON ST_Contains(polys.geom, pts.geom) WHERE polys.id IS NULL; The un-matched rows in a left join are ...


2

As far as I know, a table cannot have two geometry types (unless the type is a collection). Instead of modifying your existant table, try creating a new one: The geometry column is like any other column, it has one value for each row of the table. You are trying to create one geometry from many geometries, so what you want is not update the geometry of your ...


1

UPDATE I found a way of handling the search using FuseSearch! .I have used it in my code and it works well.Only that when I click on the output list,it doesn't show the corresponding polygon in the map. Code var options = { position: 'topright', title: 'Parcel Search', placeholder: 'Parcen No,ID, Reg Name', maxResultLength: ...


1

In your code: def EXPCODE(field_value): if field_value = "S4DNN2" return field_value "3.5" if field_value = "H2BNN2" return field_value "5.0" should probably be: def EXPCODE(field_value): if field_value == "S4DNN2": return 3.5 elif field_value == "H2BNN2": return 5.0 but if this is coming from the ...


1

How about SELECT EXISTS? According to the docs it should run until the first (if any) row is returned.


1

It's a bit difficult to determine exactly what you are trying to achieve. I've provided an example of how to handle the two scenarios that I think you are most likely trying to achieve. I have tried to keep the example short and simple, so I haven't included any SRID stuff and have just used INTs for coordinates. Scenario 1 is adding a line for each of ...



Only top voted, non community-wiki answers of a minimum length are eligible