Re: surrogate key or not?
От | Oliver Elphick |
---|---|
Тема | Re: surrogate key or not? |
Дата | |
Msg-id | 1091927196.13140.174.camel@linda обсуждение исходный текст |
Ответ на | Re: surrogate key or not? (Kenneth Gonsalves <lawgon@thenilgiris.com>) |
Ответы |
Re: surrogate key or not?
|
Список | pgsql-sql |
On Sat, 2004-08-07 at 05:00, Kenneth Gonsalves wrote: > why shouldnt the primary key change? the only key that should never change is > a key that is used as a foreign key in another table. In a table like this: > > id serial unique > name varchar primary key > > name may change - id will never change. id is used as the foreign key It can change if you use ON UPDATE CASCADE in the foreign key definitions. -- Oliver Elphick olly@lfix.co.uk Isle of Wight http://www.lfix.co.uk/oliver GPG: 1024D/A54310EA 92C8 39E7 280E 3631 3F0E 1EC0 5664 7A2F A543 10EA ======================================== "Be still before the LORD and wait patiently for him; do not fret when mensucceed in their ways, when they carry out their wicked schemes." Psalms 37:7
В списке pgsql-sql по дате отправления: