Firebird MON $ STATEMENTS insert, delete, update

I am using 2.1 firebird.

I see select commands, but I did not find the insert , update , delete command when MON$STATE = 0 . Why can't I execute the insert , update , delete command in the MON$STATEMENTS after starting? I see them when their MON$STATE = 1 , but I do not find them when their MON$STATE = 0 .

+4
source share
2 answers

MON $ STATE = 1 means that the query is executing right now. MON $ STATE = 0 means that the SELECT query has completed and is pending. that is, whether the row received by the client application is waiting, or if the end of the recordset has been reached, but the request is not yet closed.

INSERT, UPDATE, DELETE queries do not have a SUSPENDED state. They either work or are finished, and left.

+3
source

You can get MON$STATE = 0 for INSERT , UPDATE and DELETE . When your application uses prepared statements and the statement fails, the MON$STATEMENTS for this query will also have MON$STATE = 0 .

+2
source

Source: https://habr.com/ru/post/1433748/


All Articles