| От | Craig Ringer |
|---|---|
| Тема | Re: inserting to a multi-table view |
| Дата | |
| Msg-id | 48572F14.2080400@postnewspapers.com.au обсуждение исходный текст |
| Ответ на | inserting to a multi-table view ("Michael Shulman" <shulman@mathcamp.org>) |
| Ответы |
Re: inserting to a multi-table view
|
| Список | pgsql-general |
Michael Shulman wrote: > I want to be able to do INSERTs on "studentinfo" and have rows created > in both "person" and "student". This requires first inserting into > "person", capturing the "person_id" of the resulting row, and using it > to insert into "student". This seems as though it must be a common > situation. Have you considered using table inheritance to solve this? It has some limitations, and I've never seen the need myself, but it sounds like it might fit your needs. http://www.postgresql.org/docs/8.3/static/ddl-inherit.html -- Craig Ringer
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера