Re: Migrating geometry data
A highly portable way of migrating geo data from PostGIS to MySQL (and the other way round) is to go via an intermediate shapefile. Both PostGIS and MySQL have conversion routines to support this, meaning you do not have to rely on third party tools.
To convert from PostGIS to shape file, use
pgsql2shp -g geometry_column -f shapefile DB table
Then turn it into MySQL SQL:
shp2mysql -s SRID -c shapefile table DB > mysql.sql
and ingest the data:
mysql -D DB < mysql.sql
The last two steps can of course be done in one go, but the intermediate SQL file gives a better ability to check for sanity.
HTH
Ludwig
Subject
Views
Written By
Posted
13345
November 07, 2007 04:29PM
7648
November 08, 2007 02:42AM
7709
November 08, 2007 07:33AM
7225
November 09, 2007 01:18AM
Re: Migrating geometry data
11058
January 13, 2008 10:20AM
7522
February 03, 2008 06:13AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.