<div dir="ltr">Hi all,<div><br></div><div>I have issues using PostGIS after moving it to a different schema. In many but not all cases I get a "function does not exist" error with a reference to the public schema which isn't even on my search path.</div><div><br></div><div>I followed these steps to set up PostGIS:</div><div><br></div><div>docker run --name test -e POSTGRES_PASSWORD=test -e POSTGRES_USER=test -e POSTGRES_DATABASE=test -d mdillon/postgis<br>docker exec -it test /bin/bash<br>psql -U test test<br>create schema test;<br>alter schema test owner to test;<br>update pg_extension set extrelocatable = true where extname = 'postgis';<br>alter extension postgis set schema test;<br>set search_path = test;<br></div><div><br></div><div>I'm expecting to be able to use PostGIS at this point, but postgis_full_version() for example fails with:</div><div><br></div><div>ERROR:  function public.postgis_lib_version() does not exist<br></div><div><br></div><div>This on the other hand works fine:</div><div><br></div><div>SELECT ST_SnapToGrid(<br>    ST_GeomFromEWKT('LINESTRING(-1.1115678 2.123 2.3456 1.11111,4.111111 3.2374897 3.1234 1.1111, -1.11111112 2.123 2.3456 1.1111112)'),<br>    ST_GeomFromEWKT('POINT(1.12 2.22 3.2 4.4444)'),<br>    0.1, 0.1, 0.1, 0.01);<br></div><div><br></div><div>But this (from the PostGIS docs as well) doesn't:</div><div><br></div><div>SELECT ST_SnapToGrid(<br>    ST_GeomFromText('LINESTRING(1.1115678 2.123, 4.111111 3.2374897, 4.11112 3.23748667)'),<br>    0.001);<br>ERROR:  function public.st_snaptogrid(geometry, integer, integer, double precision, double precision) does not exist<br>LINE 1: SELECT public.ST_SnapToGrid($1, 0, 0, $2, $2)<br></div><div><br></div><div>Any thoughts?</div><div><br></div><div>Best regards</div></div>