Re: dump of dictionary
От | Stephan Szabo |
---|---|
Тема | Re: dump of dictionary |
Дата | |
Msg-id | Pine.BSF.4.21.0102171235150.47201-100000@megazone23.bigpanda.com обсуждение исходный текст |
Ответ на | dump of dictionary (Feite Brekeveld <feite.brekeveld@osiris-it.nl>) |
Список | pgsql-general |
On Sat, 17 Feb 2001, Feite Brekeveld wrote: > Is there a way to get a dictionary back in the (or almost the) same way > the database is created ? > > When defining: > > create table xxx ( > id varchar(10) not null, > blabla varchar(100) > ); > > > create table refxx ( > id varchar(10) not null, > other values ... > > primary key(id), > foreign key(id) references xxx(id) > ); > > > After a pg_dump you get a file with the definition of triggers that were > a result of the foreign key part in the table definition. When having a > complex database the file becomes almost unreadable. > > Is there a way to get the dictionary back in the way as stated above ? Currently, no, well at least not with post-processing (you could probably perl it back together again by reading the trigger definitions) Probably what it will end up being eventually is ALTER TABLE ADD CONSTRAINT after data load (or in schema-only dumps, after all definitions) so that recursive constraints work correctly (table a refs table b refs table a) and so that when we make it faster (doing the entire table check at once instead of a trigger call per row) it'll be faster than having the constraint in before the load.
В списке pgsql-general по дате отправления: