[firebird-support] how to resolve this deadlock

2018-09-10 Thread 'Hamish Moffatt' ham...@risingsoftware.com [firebird-support]
I have a bunch of users logging in to my system at the same time, which causes a simple query like this to run: UPDATE OR INSERT INTO G_CLASS (CLASS_NUM, CLASS_NAME, USER_NUM, SYLLABUS_NUM) VALUES (1, 'Foo', 1001, 43) The field values are identical for each - it's exactly the same query. T

RE: [firebird-support] how to resolve this deadlock

2018-09-10 Thread Hugo Eyng hugoe...@msn.com [firebird-support]
Hi Hamish. I am not sure if I understood clearly your problem. If I did, you probably should use "WITH LOCK" clause. Atenciosamente, + + Hugo Eyng + + De: firebird-support@yahoogroups.com em nome de 'Hamish Moffatt' ham...@risingsoftware.com [firebird-support

Re: [firebird-support] how to resolve this deadlock

2018-09-10 Thread Svein Erling Tysvær setys...@gmail.com [firebird-support]
Hi Hamish! What exactly do you mean by "The queries kind of don't actually conflict"? If they're trying to MERGE into the same row simultaneously, then they do actually conflict, even if they contain the same values. Strictly speaking, I think you have a 'lock conflict' and not a 'deadlock' (a pro