Currently OBS_GetBoundariesByGeometry returns the_geom and geom_refs. It would also be extremely valuable if it returned the geometry name (e.g., county name), as well as the admin levels that it is embedded within.
For example, if I was interested in getting boundaries that are just counties in Texas and I don't have the specific geometry of Texas, it would be really useful to do a WHERE filter on the name (e.g., WHERE place_name ilike '%texas%' instead of knowing the structure of the geom_ref. In a lot of cases the geom_ref isn't the useful identifier, it's the geography names.
To me, the most obvious way to pull this off is to give back two new columns: geom_name and admin_hierarchy (for all the admin levels this geom is embedded within -- so State, then Country for if US counties are requested).
Thinking through this a little more, perhaps the admin_hierarchy could be an ETL task?
Currently
OBS_GetBoundariesByGeometry
returnsthe_geom
andgeom_refs
. It would also be extremely valuable if it returned the geometry name (e.g., county name), as well as the admin levels that it is embedded within.For example, if I was interested in getting boundaries that are just counties in Texas and I don't have the specific geometry of Texas, it would be really useful to do a
WHERE
filter on the name (e.g.,WHERE place_name ilike '%texas%'
instead of knowing the structure of thegeom_ref
. In a lot of cases thegeom_ref
isn't the useful identifier, it's the geography names.To me, the most obvious way to pull this off is to give back two new columns:
geom_name
andadmin_hierarchy
(for all the admin levels this geom is embedded within -- so State, then Country for if US counties are requested).Thinking through this a little more, perhaps the
admin_hierarchy
could be an ETL task?cc @hannahblue @antoniocarlon