473,499 Members | 1,598 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

dump and sequence initilizing

Hi list,

what happens with sequences if i dump a database and i want to reload
it?

Do i have to initialize the sequences like
SELECT setval('sequence', max(id)) FROM table;
?

Best regards,
Markus
---------------------------(end of broadcast)---------------------------
TIP 9: the planner will ignore your desire to choose an index scan if your
joining column's datatypes do not match

Nov 12 '05 #1
3 2345
On Mon, Dec 15, 2003 at 13:19:48 +0100,
Markus Rebbert <ma************@freenet.de> wrote:
Hi list,

what happens with sequences if i dump a database and i want to reload
it?

Do i have to initialize the sequences like
SELECT setval('sequence', max(id)) FROM table;
?


Sequence values should be part of the dump.

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

Nov 12 '05 #2
Dear Markus Rebbert ,
what happens with sequences if i dump a database and i want to reload
it?

The pg_dump command also dumps the index value of sequences and you do
not have to do any thing
Just make sure your pg_restore and pg_dump with option --disable-tiggers

Regards,
Vishal kashyap

---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org

Nov 12 '05 #3
Am Mon, den 15.12.2003 schrieb Sai Hertz And Control Systems um 16:26:
Dear Markus Rebbert ,
what happens with sequences if i dump a database and i want to reload
it?

The pg_dump command also dumps the index value of sequences and you do
not have to do any thing
Just make sure your pg_restore and pg_dump with option --disable-tiggers


Okay, thanks.

Markus
---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

Nov 12 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
6783
by: Ravi Tallury | last post by:
Hi We are having issues with our application, certain portions of it stop responding while the rest of the application is fine. I am attaching the Java Core dump. If someone can let me know what...
3
2395
by: Chris Stiles | last post by:
Is there a human readable dump format for objects ? As opposed to pickling ? It doesn't necessarily have to be XML - in fact i'd prefer if it wasn't ;) - but ISTR an XML dump library. --...
9
3236
by: Microsoft News Server | last post by:
Hi, I am currently having a problem with random, intermittent lock ups in my ASP.net application on our production server (99% CPU usage by 3 threads, indefinately). I currently use IIS Debug...
11
3735
by: MPF | last post by:
Alas, I surrender... In a file from a COBOL dump, which is in ASCII, one of the fields is defined as S9(9) V99 Value +0. The value in this location is 0000018922D, which according to the author...
3
6678
by: Andrei Ivanov | last post by:
Hello, I have a dump created with pg_dump ver 7.4.1 from a postgres 7.4 database, with encoding SQL_ASCII. I'm trying to import this dump in a 7.4.1 postgres database with encoding UNICODE, but...
7
2034
by: Cyril VELTER | last post by:
I'm trying to dump a database from a 7.1.3 server to a 7.4.2 one. It doesn't works because of difference in COPY format (unless I use -d which is VERY slow on a 16G database). What are the...
6
11261
by: Soeren Gerlach | last post by:
Hi, some weeks ago I started to develop an application using Postgresql the first time. I'm running 7.4.3 on a Linux box with a plain 2.6.7 kernel, the storage is handled by 5 SATA disks,...
2
1797
by: Oleg | last post by:
Dear All, I have upgraded Postgresql from 7.3 to 7.4. Starting pg brings error: The database is in an older format that cannot be read by version 7.4 of PostgreSQL dpkg-upgrade postgresql...
4
3907
by: Willy Wijaya | last post by:
I have wrote this code.. But when i try to compile it using gcc in PCLinuxOS 2007, i got this message "Help me about segmentation fault (core dump)" when I run the client script.. //CLIENT...
0
7130
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7220
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6893
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7386
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5468
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
3098
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3090
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1427
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
295
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.