pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedpg_dump doesn't save correct the sequences
3+ messages / 2 participants
[nested] [flat]
* pg_dump doesn't save correct the sequences
@ 2004-10-28 05:50 Andrei Bintintan <klodoma@ar-sd.net>
0 siblings, 1 reply; 3+ messages in thread
From: Andrei Bintintan @ 2004-10-28 05:50 UTC (permalink / raw)
To: pgsql-admin
Hi to all,
I try to dump a database from a 7.4.2 postgre system and to import it on a 7.3.2. system, but I have a problem with the sequences in the dump.
This is a seq example:
CREATE SEQUENCE test_id_seq
INCREMENT BY 1
NO MAXVALUE
NO MINVALUE
CACHE 1;
This gives me an error when restoring on the 7.3 machine.
If I modify this sequence this way I can put the dump to the 7.3.2 machine:
CREATE SEQUENCE test_id_seq
START 1
INCREMENT 1
MAXVALUE 9223372036854775807
MINVALUE 1
CACHE 1;
I don't know what happened, because last week I also put a dump from 7.4 to 7.3 without any problems.
A coelege from me made an application and some modifications in the 7.4 database system, now I see that in every database there are these tables that weren't before: sql_features, sql_implementation_info, sql_languages, sql_packages, sql_sizing, sql_sizing_profiles.
Please advice.
Thanx.
Andy.
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: pg_dump doesn't save correct the sequences
@ 2004-10-28 06:22 Stephan Szabo <sszabo@megazone.bigpanda.com>
parent: Andrei Bintintan <klodoma@ar-sd.net>
0 siblings, 1 reply; 3+ messages in thread
From: Stephan Szabo @ 2004-10-28 06:22 UTC (permalink / raw)
To: Andrei Bintintan <klodoma@ar-sd.net>; +Cc: pgsql-admin
On Thu, 28 Oct 2004, Andrei Bintintan wrote:
> I try to dump a database from a 7.4.2 postgre system and to import it on
> a 7.3.2. system, but I have a problem with the sequences in the dump.
In general, the above is not guaranteed to work. pg_dump will use features
of the dumping version so moving the dump to an earlier version is filled
with danger.
> This is a seq example:
>
> CREATE SEQUENCE test_id_seq
> INCREMENT BY 1
> NO MAXVALUE
> NO MINVALUE
> CACHE 1;
>
> This gives me an error when restoring on the 7.3 machine.
Looking at the documentation, it looks like NO MAXVALUE and NO MINVALUE
were added in 7.4.
> I don't know what happened, because last week I also put a dump from 7.4
> to 7.3 without any problems.
> A coelege from me made an application and some modifications in the 7.4
> database system, now I see that in every database there are these tables
> that weren't before: sql_features, sql_implementation_info,
> sql_languages, sql_packages, sql_sizing, sql_sizing_profiles.
I believe these are part of the SQL standard information_schema.
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: pg_dump doesn't save correct the sequences
@ 2004-10-28 16:51 Andrei Bintintan <klodoma@ar-sd.net>
parent: Stephan Szabo <sszabo@megazone.bigpanda.com>
0 siblings, 0 replies; 3+ messages in thread
From: Andrei Bintintan @ 2004-10-28 16:51 UTC (permalink / raw)
To: Stephan Szabo <sszabo@megazone.bigpanda.com>; +Cc: pgsql-admin
Okay, If I modify all the Sequences in the dump, everything works fine.
Is there any possibility to specify to the pg_dump to save the sequences
with the "old" type??? I mean not with No MAXVALUE and No Minvalue???
My problem is that the 7.3 database I cannot "update" it for the moment for
diverse reasons, and I would like not to modify any dump anymore.
A strange thing is that this type of dump already worked once....
----- Original Message -----
From: "Stephan Szabo" <sszabo@megazone.bigpanda.com>
To: "Andrei Bintintan" <klodoma@ar-sd.net>
Cc: <pgsql-admin@postgresql.org>
Sent: Thursday, October 28, 2004 9:22 AM
Subject: Re: [ADMIN] pg_dump doesn't save correct the sequences
>
> On Thu, 28 Oct 2004, Andrei Bintintan wrote:
>
> > I try to dump a database from a 7.4.2 postgre system and to import it on
> > a 7.3.2. system, but I have a problem with the sequences in the dump.
>
> In general, the above is not guaranteed to work. pg_dump will use features
> of the dumping version so moving the dump to an earlier version is filled
> with danger.
>
> > This is a seq example:
> >
> > CREATE SEQUENCE test_id_seq
> > INCREMENT BY 1
> > NO MAXVALUE
> > NO MINVALUE
> > CACHE 1;
> >
> > This gives me an error when restoring on the 7.3 machine.
>
> Looking at the documentation, it looks like NO MAXVALUE and NO MINVALUE
> were added in 7.4.
>
> > I don't know what happened, because last week I also put a dump from 7.4
> > to 7.3 without any problems.
>
> > A coelege from me made an application and some modifications in the 7.4
> > database system, now I see that in every database there are these tables
> > that weren't before: sql_features, sql_implementation_info,
> > sql_languages, sql_packages, sql_sizing, sql_sizing_profiles.
>
> I believe these are part of the SQL standard information_schema.
>
> ---------------------------(end of broadcast)---------------------------
> TIP 8: explain analyze is your friend
>
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2004-10-28 16:51 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2004-10-28 05:50 pg_dump doesn't save correct the sequences Andrei Bintintan <klodoma@ar-sd.net>
2004-10-28 06:22 ` Stephan Szabo <sszabo@megazone.bigpanda.com>
2004-10-28 16:51 ` Andrei Bintintan <klodoma@ar-sd.net>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox