Skip site navigation (1) Skip section navigation (2)

Re: Restore postgres database problem

From: Luis Sousa <llsousa(at)ualg(dot)pt>
To: Inpreet Singh <Singh(dot)Inpreet(at)netsity(dot)com>
Cc: pgsql-admin <pgsql-admin(at)postgresql(dot)org>
Subject: Re: Restore postgres database problem
Date: 2005-01-27 10:01:27
Message-ID: 41F8BBF7.6070600@ualg.pt (view raw or flat)
Thread:
Lists: pgsql-admin
The command I use for dump is: pg_dump -Fc -h <host name> <database 
name> > <dump file>
For restore, I create the database first on pgsql, and then (on shell) I 
give the command: pg_restore -d <database name> <dump file>

Luis Sousa

Inpreet Singh wrote:

>*Taken Dump :*   /usr/bin/pg_dumpall > /home/inpreet/postgres.sql  /*which
>was taken at client site*/
>
>*Restoring Dump :*   su - postgres /*This process I am doing*/
> /usr/local/pgsql/bin/psql -d template1 < /home/inpreet/postgres.sql
>
>Sir I have some table values which are of type timestamp and those columns
>have values like
>""2004-10-09 10:03:36.689993"". So is it possible that when I am restoring
>values this columns are creating all sort of trouble??? as timestamp field
>means date time at the time of insertion of record and I am trying to insert
>earlier date time.
>
>Regards
>Inpreet Singh
>
>----- Original Message ----- 
>From: "Luis Sousa" <llsousa(at)ualg(dot)pt>
>To: "Inpreet Singh" <Singh(dot)Inpreet(at)netsity(dot)com>
>Sent: Wednesday, January 26, 2005 3:38 PM
>Subject: Re: [ADMIN] Restore postgres database problem
>
>
>  
>
>>Which options did you use to dump data?
>>And which options did you use to restore it?
>>Please submit the command lines used.
>>
>>Luis Sousa
>>
>>Inpreet Singh wrote:
>>
>>    
>>
>>>Hello,
>>>I am using postgres 7.3.4. I am trying to restore database dump using
>>>psql command but getting following error.
>>>
>>>*Taken Dump :*   /usr/bin/pg_dumpall > /home/inpreet/postgres.sql
>>>*Restoring Dump :*   su - postgres
>>>/usr/local/pgsql/bin/psql -d template1 < /home/inpreet/postgres.sql
>>>
>>>but getting error
>>>ERROR:  copy: line 32, Bad date external representation '\N
>>>lost synchronization with server, resetting connection
>>>
>>>Please tell me which way to go.
>>>
>>>Thanks a*n*d Regards
>>>*Inpreet Singh*
>>>
>>>
>>>      
>>>
>>    
>>
>
>
>  
>

In response to

pgsql-admin by date

Next:From: Victor DanilchenkoDate: 2005-01-27 15:01:48
Subject: Help with access control settings in pg_hba.conf -- AAAARGH!
Previous:From: Inpreet SinghDate: 2005-01-27 05:33:43
Subject: Re: Restore postgres database problem

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group