Re: Inheritance and shared sequence
| От | Richard Huxton |
|---|---|
| Тема | Re: Inheritance and shared sequence |
| Дата | |
| Msg-id | 4667C557.5000600@archonet.com обсуждение исходный текст |
| Ответ на | Inheritance and shared sequence ("Sebastjan Trepca" <trepca@gmail.com>) |
| Ответы |
Re: Inheritance and shared sequence
|
| Список | pgsql-general |
Sebastjan Trepca wrote: > Hi, > > as I understood, when you create a table which inherits some other > table, the constraints and indexes do not go to the child table hence > you have to create a separate ones in there. That means you cannot > depend that you won't have duplicate IDs in both tables. Right? > > BUT...what if child table and parent table both use the same sequence > for the primary key. Would the duplication still be an issue? Well, if you *always* use the sequence you'll be OK (until you run out of numbers), but it won't stop you manually supplying your own values. -- Richard Huxton Archonet Ltd
В списке pgsql-general по дате отправления: