Hi,
How I convert a shp file to sql pointing to a particular schema and
database?
As the trivial operation of converting shp to sql is ok!
Is possible?
Thanks!
--
Rogério A. B. da Silva
Geóg. B. Sc.
___
postgis-users mailing list
Oi Rogério,
I use ogr2ogr, which is more generic than shp2pgsql. You can choose the
schema (active_schema option) and the name of the table (-nln option).
Something like:
ogr2ogr -f PostgreSQL PG:host=xxx.di.uminho.pt user=xxx
dbname=arhnorte password=yyy active_schema=atlas -a_srs
Command options :
http://www.bostongis.com/pgsql2shp_shp2pgsql_quickguide_20.bqg
The schema is specified in the same time as table name.
Regarding the database, you have to specify it when using psql with the
-d option
You can also do this in one step using the shp2pgsql-gui .
Cheers,
Rémi-C
Please note that
_ogr2ogr is faster (5 times?)
_ogr2ogr is less reliable (bugs!)
Cheers,
Rémi-C
2014-04-16 15:12 GMT+02:00 J. Gustavo Rocha j...@di.uminho.pt:
Oi Rogério,
I use ogr2ogr, which is more generic than shp2pgsql. You can choose the
schema (active_schema option) and the name of
Hope this helps.
shp2pgsql -I -s 4326 -W latin1 source_shp.shp schema_xxx.table_xxx
|psql -U user -W -d database_name -h localhost
https://bitbucket.org/jgrocha/moradas/commits/c021586584b659afda4f0c2a1e24d4d065b1498f#add-comment
Regards,
Toze
On 16-04-2014 15:35, Rémi Cura wrote:
Please
Sent from Samsung Mobile
Hi,
The problem I have is similar to this one from an old thread on this list:
https://www.mail-archive.com/postgis-users@lists.osgeo.org/msg00013.html
I have never succeeded to load a raster into PostGIS on my machine. In
the past, I have experienced the same type