recreating table and foreign keys

Поиск
Список
Период
Сортировка
От Tomasz Myrta
Тема recreating table and foreign keys
Дата
Msg-id 20021203170324.M63387@klaster.net
обсуждение исходный текст
Ответы Re: recreating table and foreign keys  (Stephan Szabo <sszabo@megazone23.bigpanda.com>)
Список pgsql-sql
Hi
I use Postgresql 7.2.2.
Sometimes I have to remove a column from my tables (psql):
1. alter table master_table rename to x;
2. \i tables.sql
3. insert into master_table select f1,f2,... from x
4. drop table x

I think, foreign keys referring from detail_table(s) to master_table 
have gone.
How to recreate foreign keys? I want to keep my database in better 
integrity, than now...

Tomasz Myrta






В списке pgsql-sql по дате отправления:

Предыдущее
От: "Berman, Phil"
Дата:
Сообщение: Backend message type 0x50 arrived while idle
Следующее
От: "Troy"
Дата:
Сообщение: Re: [OT] Inventory systems (private)