Subject Re: [firebird-support] UPDATE or INSERT and Crash without Commit,and WAIT TRNX
Author Helen Borrie
At 12:07 AM 3/07/2003 +0000, you wrote:
>this a serious problem with transaction
> UPDATE "Table1"
> SET "Field1"=5
> WHERE "Field2"=1
>then my app crashed without commit or rollback :-(

It sounds like a problem with your app when posting the DML. Does your app
trap exceptions? You will get AVs from trying to operate on unprepared
queries. Many types of exceptions can occur, before a statement gets
posted or committed. You will get server errors from trying to prepare or
post invalid statements. Your exception handling must deal with these when
they occur. If not, your application cannot proceed and it will crash or hang.

Ask about this on a Delphi forum if you don't understand it.

>when another user do this with Wait transaction and NoRecordVersion
> UPDATE "Table1"
> SET "Field1"=6
> WHERE "Field2"=1
>it wait forever :-O
>i know i can use nowait but i has deadlock, how to fix it without
>restarting server

Fix your application so that it is capable of handling conflicts. If you
are not handling the exceptions (including conflicts) then using WAIT
transactions is guaranteed to hang up your application.

Restarting the server will not fix the bugs in your application.

>i try use gfix "mydb.fdb" -user sysdba -password ***** -commit all
>but nothing happen

gfix is a database housekeeping and repair tool. It won't fix your
application code bugs either.

>i use firebird 1.5rc3 delphi ibx

Later versions of ibx are likely to have their own problems with Firebird,
and more so with a Firebird beta. There is NO solution for that. IBX is a
commercial Borland product designed for use with Borland's InterBase
products. Even when you fix up your application code, there is no
guarantee that IBX will work with a Firebird 1.5 database. You will need
to use components that support Firebird (IBO, FIBPlus, DBX with the
Firebird driver, etc.)