]> granicus.if.org Git - postgis/commitdiff
Wrap most topology.sql into a transaction
authorSandro Santilli <strk@keybit.net>
Tue, 27 Mar 2012 17:30:43 +0000 (17:30 +0000)
committerSandro Santilli <strk@keybit.net>
Tue, 27 Mar 2012 17:30:43 +0000 (17:30 +0000)
CREATE SCHEMA is left out because uninstall_topology isn't getting
rid of it (to be fixed later)

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

topology/topology.sql.in.c

index 4273ece4d6420456cc8d8497a26cca47899f40a8..25f9a06b3a51c06050fb15253ab272c4a61c03aa 100644 (file)
 -- Let people decide about that
 -- DROP SCHEMA topology CASCADE;
 
+CREATE SCHEMA topology;
+
 -- Doing everything outside of a transaction helps
 -- upgrading in the best case.
--- BEGIN;
-
-CREATE SCHEMA topology;
+BEGIN;
 
 --={ ----------------------------------------------------------------
 --  POSTGIS-SPECIFIC block
@@ -1982,6 +1982,7 @@ CREATE OR REPLACE FUNCTION postgis_topology_scripts_installed() RETURNS text
        AS _POSTGIS_SQL_SELECT_POSTGIS_SCRIPTS_VERSION
        LANGUAGE 'sql' IMMUTABLE;
 
---COMMIT;
 -- Make sure topology is in database search path --
 SELECT topology.AddToSearchPath('topology');
+
+COMMIT;