PLEASE MAKE SURE YOU BACKUP YOUR PUBLIC SCHEMA ! Steps: Open up pgAdmin III and connect to PostgreSQL. Select desired database and click on schemas Open up SQL Editor Open & execute public_schema.sql Open & execute public_data.sql Open rename_schema.sql and replace `new_schema_name` with the name you want, then execute the query Files can be found here: PostGIS Enabled Schema
Please check geometry_columns table if the result return `-1`. You may change the srid value if you knew the value of the target table. Value can be 900913, 4326, 3857, etc.
ST_AsText – represent geometry as WKT ST_Transform – transform geometry from one projection to another ST_GeomFromText – represent WKT as geometry Reference: PostGIS 1.5 Manual
Just a note, do run ‘legacy.sql‘ when migrate from PostGIS 1.5 to PostGIS 2.0 because there’s functions being removed from 1.5. so we need it back. Reference: http://postgis.refractions.net/docs/PostGIS_FAQ.html#legacy_faq
A good tutorial on WFS-T. Didn’t try it yet, but will try it soon. http://www.gistutor.com/openlayers/22-advanced-openlayers-tutorials/47-openlayers-wfs-t-using-a-geoserver-hosted-postgis-layer.html