| От | Benjamin Krajmalnik |
|---|---|
| Тема | Error inserting row on unique key |
| Дата | |
| Msg-id | 8511B4970E0D124898E973DF496F9B4325157D@stash.stackdump.local обсуждение |
| Ответы |
Re: Error inserting row on unique key
|
| Список | pgsql-admin |
I have a large table which uses a sequence for column which is defined as the primary key. Our systems is a real time data acquisition system, so we have "insert" statements going through it wrapped inside storedprocedure. Every once in a while I get an inserio error on a violation of a unique constraint on the primary key. Could this be caused by a subsequent call to the stored procedure which took place before the sequence on the prior storedprocedure fired? If so, do you recommend taking the call to the sequence out of the columns constraint definition and manually calling itas the firs step in the SP call? As I said, this does not happen very often, but I have seen it happen. Regards, Benjamin
В списке pgsql-admin по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера