From: | "Jochen Schwarz" <js(at)webmail(dot)eurodata(dot)de> |
---|---|
To: | pgsql-bugs(at)postgresql(dot)org |
Subject: | BUG #3857: pg_restore -t tablename doesn't restore constraints of this table |
Date: | 2008-01-08 15:02:22 |
Message-ID: | 200801081502.m08F2MES052041@wwwmaster.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
The following bug has been logged online:
Bug reference: 3857
Logged by: Jochen Schwarz
Email address: js(at)webmail(dot)eurodata(dot)de
PostgreSQL version: 8.2.6
Operating system: Windows and Linux
Description: pg_restore -t tablename doesn't restore constraints of
this table
Details:
pg_restore doesn't restore constraints if you only restore a table.
Here is a test-scenario:
create database test;
create table testtable ( id integer primary key );
test=# \d testtable
Tabelle public.testtable
Spalte | Typ | Attribute
--------+---------+-----------
id | integer | not null
Indexe:
testtable_pkey PRIMARY KEY, btree (id)
pg_dump -F c test >/tmp/test.dmp
drop table testtable;
pg_restore -F c -d test -t testtable /tmp/test.dmp
test=# \d testtable
Tabelle public.testtable
Spalte | Typ | Attribute
--------+---------+-----------
id | integer | not null
the primary key testtable_pkey is not restored!
pg_restore -F c -d test -I testtable_pkey is not working either.
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2008-01-08 16:05:50 | Re: BUG #3855: backend sends corrupted data on EHOSTDOWN error |
Previous Message | Diego Spano | 2008-01-08 13:29:11 | Re: BUG #3850: Incompatibility among pg_dump / pg_restore. |