| От | Richard Huxton |
|---|---|
| Тема | Re: get sequence value of insert command |
| Дата | |
| Msg-id | 419DBC5C.807@archonet.com обсуждение исходный текст |
| Ответ на | Re: get sequence value of insert command (Achilleus Mantzios <achill@matrix.gatewaynet.com>) |
| Список | pgsql-sql |
Achilleus Mantzios wrote: >> >>now how do i know the id of my newly inserted element? and >>how can this be done in a completely concurrency safe way? > > > The way to do this is by reading the docs :) > > use currval, it is session safe. The increase in this question suggests the number of new users has increased since 8.0 went into beta-test. It's pretty much the first question anyone asks. I seem to recall it was mine. I made the mistake of assuming it wasn't concurrency safe and was gently corrected by one of the community. I think it might have been a Tim/Tam Lane. Wonder what happened to him? :-) -- Richard Huxton Archonet Ltd
В списке pgsql-sql по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера