]> granicus.if.org Git - postgis/commitdiff
Make topology.CreateTopology unknown-srid-agnostic (uses ST_Srid to tell)
authorSandro Santilli <strk@keybit.net>
Tue, 4 Oct 2011 14:33:23 +0000 (14:33 +0000)
committerSandro Santilli <strk@keybit.net>
Tue, 4 Oct 2011 14:33:23 +0000 (14:33 +0000)
Hopefully this makes the topology code stable during the SRID fights :)

git-svn-id: http://svn.osgeo.org/postgis/trunk@7936 b70326c6-7e19-0410-871a-916f4a2858ee

topology/topology.sql.in.c

index d950fa62f59f68abba51321ede6820c7d6ff5141..1261e06bb8466292e291c15857976194f290679d 100644 (file)
@@ -1866,10 +1866,10 @@ RETURNS integer AS
 ' SELECT topology.CreateTopology($1, $2, 0); '
 LANGUAGE 'SQL' VOLATILE STRICT;
 
---  CreateTopology(name) -- srid = -1, precision = 0
+--  CreateTopology(name) -- srid = unknown, precision = 0
 CREATE OR REPLACE FUNCTION topology.CreateTopology(varchar)
 RETURNS integer AS
-' SELECT topology.CreateTopology($1, -1, 0); '
+$$ SELECT topology.CreateTopology($1, ST_SRID('POINT EMPTY'::geometry), 0); $$
 LANGUAGE 'SQL' VOLATILE STRICT;
 
 --} CreateTopology