[postgis-tickets] [PostGIS] #3486: function st_within

PostGIS trac at osgeo.org
Wed Mar 2 03:09:43 PST 2016


#3486: function st_within
------------------------------------------------+--------------------------
 Reporter:  giau81                              |      Owner:  pramsey
     Type:  defect                              |     Status:  new
 Priority:  medium                              |  Milestone:  PostGIS
                                                |  2.2.2
Component:  postgis                             |    Version:  2.2.x
 Keywords:  st_within,st_Contains, search_path  |
------------------------------------------------+--------------------------
 st_within(geometry, geometry)/st_Contains(geometry, geometry) call 'SELECT
 $1 && $2 AND _ST_Contains($2,$1)' without setting public schema to
 _ST_Contains function.

 Using "set search_path = schema_name", if schema_name is not "public", the
 functions st_within(geometry, geometry)/st_Contains(geometry, geometry)
 don't work, because they call schema_name._ST_Contains($2,$1) instead of
 public._ST_Contains($2,$1).

 This problem happens during db restoring processes.
 We solve this issue modifying the function like this:
 'SELECT $1 && $2 AND public._ST_Contains($2,$1)'

--
Ticket URL: <https://trac.osgeo.org/postgis/ticket/3486>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.


More information about the postgis-tickets mailing list