[postgis-users] RV: How export a postgreSQL/GIS
Juanse
georef at tie.cl
Thu Oct 24 11:20:56 PDT 2002
We solved by using
pg_dump -f tablas.sql ejercicio
and dumps everything
Juanse
temuko-chile
----- Original Message -----
From: Chris Hodgson
To: postgis-users at postgis.refractions.net
Sent: Thursday, October 24, 2002 2:15 PM
Subject: Re: [postgis-users] RV: How export a postgreSQL/GIS
Actually, I'm told that you won't get views dumped if you use this method, whereas -t "*" dumps the views as well.
Chris
----- Original Message -----
From: Chris Hodgson
To: postgis-users at postgis.refractions.net
Sent: Thursday, October 24, 2002 10:05 AM
Subject: Re: [postgis-users] RV: How export a postgreSQL/GIS
At first, it doesn't seem possible to use pg_dump to dump sequences - it says on the man page:
"pg_dump will save the information necessary to re-generate all user-defined types, functions, tables, indexes, aggregates, and operators."
That seems to be a rather complete list that doesn't contain "sequences" - in fact they aren't mentioned anywhere in the doc.
However, after more careful reading, sequences aren't treated as special entities by postgres, they are just tables on which the nextval, setval, etc. functions work. I guess because of their status as "sequences", -t "*" doesn't include them. However, if you either specify the name of the sequence specifically using -t seq_name or simply leave out the -t parameter altogether, sequences do get dumped (as tables, with setval() function calls afterward).
So try:
pg_dump -f tablas.sql ejercicio
And I think you will get everything dumped.
Chris
----- Original Message -----
From: Juanse
To: postgis-users at postgis.refractions.net
Sent: Wednesday, October 23, 2002 9:45 PM
Subject: [postgis-users] RV: How export a postgreSQL/GIS
I am trying to export a postgreSQL/postGIS database to on other computer.
we are doing a :
pg_dump -t "*" -f tablas.sql ejercicio
to prepare the table to ftp it.
how ever we get everything out except the sequences on the new "tablas" database.
what are we doing wrong? or better how we should do it?
Juanse
temuko-chile
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.401 / Virus Database: 226 - Release Date: 10/10/02
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.401 / Virus Database: 226 - Release Date: 09/10/02
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20021024/bd4b000e/attachment.html>
More information about the postgis-users
mailing list