trigger insert duplicate rows question
От | T.R.Missner@Level3.com |
---|---|
Тема | trigger insert duplicate rows question |
Дата | |
Msg-id | EBFCF3982143D511A77F0008C716807E0106DB30@N0400IDC1.oss.level3.com обсуждение исходный текст |
Ответы |
Re: trigger insert duplicate rows question
|
Список | pgsql-general |
I have designed a trigger that will insert a row in a table if a check to see if the row is already there fails. Everything works as expected when running slow or with few threads. but when I kick up the threads that handle the initial insert that 'triggers' the trigger I run into some trouble. It seems that in some cases after the trigger function has done a selct to see it the data already exist then moves on to the insert the insert fails because another thread has already finished inserting the same row. I get an error about duplicate rows etc. This in itself is really not a problem. What I would like to do is suppress the error message somehow. I am using jdbc on the client side and can't figure out how to suppress the error from going to stdout. Can I capture it in the procedure code? Any other suggestions? Is there a way to get a return from the insert statement in the prodecure? thanks in advance. t.r. missner
В списке pgsql-general по дате отправления: