Re: [GENERAL] dumping table contents in a sensible order

2016-11-15 Thread Chris Withers
On 16/11/2016 01:05, Adrian Klaver wrote: INSERT 0 1 ERROR: insert or update on table "table_one" violates foreign key constraint "table_one_parent_id_fkey" DETAIL: Key (parent_id)=(xxx) is not present in table "table_one". So, the problem appears to be that table_one is self-referential by

Re: [GENERAL] dumping table contents in a sensible order

2016-11-15 Thread Adrian Klaver
On 11/15/2016 02:56 PM, Chris Withers wrote: Hi All, I have a database that I want to dump three tables from, for use in development. They form a subset of the data, so I was dumping like this: pg_dump thedatabase --inserts -t table_one -t depends_on_table_one -t depends_on_previous_two >

Re: [GENERAL] dumping table contents in a sensible order

2016-11-15 Thread bto...@computer.org
- Original Message - > From: "Chris Withers" > Sent: Tuesday, November 15, 2016 5:56:11 PM > > I have a database that I want to dump three tables from, for use in > development. They form a subset of the data, so I was dumping like this: > > pg_dump thedatabase

Re: [GENERAL] dumping table contents in a sensible order

2016-11-15 Thread Jerry Sievers
Chris Withers writes: > Hi All, > > I have a database that I want to dump three tables from, for use in > development. They form a subset of the data, so I was dumping like > this: > > pg_dump thedatabase --inserts -t table_one -t depends_on_table_one -t >

[GENERAL] dumping table contents in a sensible order

2016-11-15 Thread Chris Withers
Hi All, I have a database that I want to dump three tables from, for use in development. They form a subset of the data, so I was dumping like this: pg_dump thedatabase --inserts -t table_one -t depends_on_table_one -t depends_on_previous_two > dump.sql However, when I try to load this