FirebirdSQL / firebird

Firebird server, client and tools
https://www.firebirdsql.org/
1.26k stars 217 forks source link

[isql] Wrong message "Rolling back work" when have "set transaction" inside script #8013

Open gladiston opened 8 months ago

gladiston commented 8 months ago

clientes.zip

This script running well as: isql -ch iso8859_1 clientes.sql but always says: "Rolling back work" Despite this, everything worked fine. Maybe this message is a bug.

On the Firebird support forum, some guys suggest that "commit;^" instead of just "commit^" are tricking the program.

mrotteveel commented 8 months ago

The problem is not the commit;^ vs commit^. The problem seems to be that explicitly starting a transaction with set transaction will result in ISQL always printing out the "Rolling back work" message, even if the last transaction was committed.

gladiston commented 8 months ago

I´am not intent to start a transaction, just specify/set a TIL with lock timeout. You think that I need to put an explicit 'start(begin) transaction'?

mrotteveel commented 8 months ago

There is no such command in Firebird or ISQL. What you're doing is fine, the problem is what ISQL does after any set transaction statement has occurred in the script.

Also, everything in Firebird is done in transactions (even if you don't execute set transaction, ISQL will start one with default settings).

gladiston commented 8 months ago

So it's a small bug that just has to do with a message that shouldn't appear, a bug of minimal concern. Thanks for tips.