Re: ERROR: duplicate key value violates unique constraint "geocode_settings_pkey"

From: Ankur Kaushik <ankurkaushik(at)gmail(dot)com>
To: Albe Laurenz <laurenz(dot)albe(at)wien(dot)gv(dot)at>
Cc: "pgsql-admin(at)postgresql(dot)org" <pgsql-admin(at)postgresql(dot)org>
Subject: Re: ERROR: duplicate key value violates unique constraint "geocode_settings_pkey"
Date: 2015-06-17 10:04:34
Message-ID: CALXoLqxGFNYDESrgTFrWBYD0Zg6pMLEGE1JNpzaZBvf1_mcEQQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: 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(dot)albe(at)wien(dot)gv(dot)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
>

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Albe Laurenz 2015-06-17 12:15:56 Re: ERROR: duplicate key value violates unique constraint "geocode_settings_pkey"
Previous Message Albe Laurenz 2015-06-17 09:43:27 Re: ERROR: duplicate key value violates unique constraint "geocode_settings_pkey"