Start read only transactions not work
Posted: Thu 13 Jan 2022 12:48
Hello, I'm performing some tests where I need to perform a query in the database in read-only mode, that is, I want to start a read-only transaction, consult the data and close this transaction.
I did several tests configuring transaction isolation, but I may be doing something wrong as it is not querying with the isolation I request.
Can you give me a correct example of how to use it?
Sample:
Thanks.
Best Regarts;
I did several tests configuring transaction isolation, but I may be doing something wrong as it is not querying with the isolation I request.
Can you give me a correct example of how to use it?
Sample:
Code: Select all
IBCConnection1.DefaultTransaction.IsolationLevel := iblReadOnlyReadCommitted;
IBCConnection1.Open;
IBCConnection1.StartTransaction;
IBCQuery1.Close;
IBCQuery1.SQL.Text := 'select * from test';
IBCQuery1.Open;
IBCConnection1.Commit;
Thanks.
Best Regarts;