From: Chris Hodgson Date: Thu, 6 Mar 2003 18:29:35 +0000 (+0000) Subject: changed 'geometry' to 'GEOMETRY' two places in the AddGeometryColumn sql code. X-Git-Tag: pgis_0_7_5~7 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=0e254544ba6c2b81aaaa9846570e24cb4734e885;p=postgis changed 'geometry' to 'GEOMETRY' two places in the AddGeometryColumn sql code. git-svn-id: http://svn.osgeo.org/postgis/trunk@246 b70326c6-7e19-0410-871a-916f4a2858ee --- diff --git a/Attic/postgis_sql_common.sql.in b/Attic/postgis_sql_common.sql.in index 817fcaab2..796dc5da6 100644 --- a/Attic/postgis_sql_common.sql.in +++ b/Attic/postgis_sql_common.sql.in @@ -178,7 +178,7 @@ DECLARE BEGIN - IF (not( (new_type =''geometry'') or (new_type =''GEOMETRYCOLLECTION'') or (new_type =''POINT'') + IF (not( (new_type =''GEOMETRY'') or (new_type =''GEOMETRYCOLLECTION'') or (new_type =''POINT'') or (new_type =''MULTIPOINT'') or (new_type =''POLYGON'') or (new_type =''MULTIPOLYGON'') or (new_type =''LINESTRING'') or (new_type =''MULTILINESTRING'')) ) THEN RAISE EXCEPTION ''Invalid type name - valid ones are: GEOMETRY, GEOMETRYCOLLECTION,POINT,MULTIPOINT,POLYGON,MULTIPOLYGON,LINESTRING, or MULTILINESTRING ''; @@ -213,7 +213,7 @@ BEGIN EXECUTE ''ALTER TABLE "'' ||table_name||''" ADD CHECK (SRID("'' || column_name || ''") = '' || new_srid || '')'' ; - IF (not(new_type = ''geometry'')) THEN + IF (not(new_type = ''GEOMETRY'')) THEN EXECUTE ''ALTER TABLE "'' ||table_name||''" ADD CHECK ( geometrytype("''||column_name||''")=''|| quote_literal(new_type)||'' OR ('' ||column_name ||'') is null)''; END IF;