Re: Geographic data sources, queries and questions
От | Ron Johnson |
---|---|
Тема | Re: Geographic data sources, queries and questions |
Дата | |
Msg-id | 465D246D.8080109@cox.net обсуждение исходный текст |
Ответ на | Re: Geographic data sources, queries and questions (Michael Glaesemann <grzm@seespotcode.net>) |
Ответы |
Re: Geographic data sources, queries and questions
|
Список | pgsql-general |
On 05/29/07 17:46, Michael Glaesemann wrote: > > On May 29, 2007, at 15:28 , John D. Burger wrote: > >> Even ISO country codes are not guaranteed to be stable > > I'm not sure where the idea that primary keys must be stable comes from. > There's nothing necessarily wrong with updating a primary key. All a > primary key does is uniquely identify a row in a table. If that id > changes over time, that's fine, as long as the primary key columns > continue to uniquely identify each row in the table. And any archived data (for example, transaction detail that you must keep for 7 years but don't still want in your database, since it doubles your backup/restore times) will still have the old codes. "Static" data needs to be static. > SQL even provides > ON UPDATE CASCADE to make this convenient. There may be performance > arguments against updating a primary key (as the changes need to > propagate), but that depends on the needs of a particular (benchmarked > and tested) application environment. -- Ron Johnson, Jr. Jefferson LA USA Give a man a fish, and he eats for a day. Hit him with a fish, and he goes away for good!
В списке pgsql-general по дате отправления: