Name

DropGeometryColumn — Drops a spatial column from an existing feature table.

Synopsis

varchar DropGeometryColumn(varchar catalogue, varchar schema, varchar table, varchar column);

varchar DropGeometryColumn(varchar schema, varchar table, varchar column);

varchar DropGeometryColumn(varchar table, varchar column);

Description

The DropGeometryColumn method will :

  • drop the spatial reference Check Constraint on the feature table

  • drop the entry from the GEOMETRY_COLUMNS table

  • drop the geometry column from the feature table

Coordinate Dimensions
2D3DM
Spatial Standards Support
OGC SFS for SQL. 1.1 (1999)OGC SFS for SQL. 1.1.0 (2005)OGC SFS for SQL. 1.2.0 (2006)SQL-MM Part 3
2.3.86.2.7--

Examples

PostgreSQL
--(1) <catalogue>, <schema>, <table>, <column>, <srid>, <type>, <dim>
SELECT DropGeometryColumn ('','public','test','geom_point');

          dropgeometrycolumn
---------------------------------------
"public.test.geom_point effectively removed."
(1 row)

--(2) <schema>, <table>, <column>, <srid>, <type>, <dim>
SELECT DropGeometryColumn ('public','test','geom_polygon');

          dropgeometrycolumn
---------------------------------------
"public.test.geom_polygon effectively removed."
(1 row)

--(3) <table>, <column>, <srid>, <type>, <dim>
SELECT DropGeometryColumn ('test','geom_line');

          dropgeometrycolumn
---------------------------------------
"public.test.geom_line effectively removed."
(1 row)
H2
--(1) <catalogue>, <schema>, <table>, <column>, <srid>, <type>, <dim>
SELECT DropGeometryColumn ('','PUBLIC','TEST','geom_point');
--Result
PUBLIC.TEST.geom_point effectively removed.

--(2) <schema>, <table>, <column>, <srid>, <type>, <dim>
SELECT DropGeometryColumn ('PUBLIC','TEST','geom_polygon');
--Result
PUBLIC.TEST.geom_polygon effectively removed.

--(3) <table>, <column>, <srid>, <type>, <dim>
SELECT DropGeometryColumn ('TEST','geom_line');
--Result
PUBLIC.TEST.geom_line effectively removed.

Related functions

AddGeometryColumn