Re: ERROR: duplicate key value violates unique constraint "geocode_settings_pkey" - Mailing list pgsql-admin

From Ankur Kaushik
Subject Re: ERROR: duplicate key value violates unique constraint "geocode_settings_pkey"
Date
Msg-id CALXoLqxGFNYDESrgTFrWBYD0Zg6pMLEGE1JNpzaZBvf1_mcEQQ@mail.gmail.com
Whole thread Raw
In response to Re: ERROR: duplicate key value violates unique constraint "geocode_settings_pkey"  (Albe Laurenz <laurenz.albe@wien.gv.at>)
Responses Re: ERROR: duplicate key value violates unique constraint "geocode_settings_pkey"
List pgsql-admin
Yes I have checked now using -c with pg_dump is right way to take backup and restore . which has worked fine for me.

One more question which is faster way to restore psql < dump.sql or using pg_restore ?

On Wed, Jun 17, 2015 at 3:13 PM, Albe Laurenz <laurenz.albe@wien.gv.at> wrote:
Ankur Kaushik wrote:
> So is there any way to restore database without any error , or Can we put one line in database backup
> file , DROP TABLE 'table name' just before CREATE TABLE.

You mean like the -c option in pg_dump or pg_restore?

Yours,
Laurenz Albe

pgsql-admin by date:

Previous
From: Albe Laurenz
Date:
Subject: Re: ERROR: duplicate key value violates unique constraint "geocode_settings_pkey"
Next
From: Albe Laurenz
Date:
Subject: Re: ERROR: duplicate key value violates unique constraint "geocode_settings_pkey"