[Lazarus] SQLDb and TSQLQuery usage for MSSQL database...

Bo Berglund bo.berglund at gmail.com
Thu Feb 25 09:55:09 CET 2016


On Thu, 25 Feb 2016 08:57:40 +0100 (CET), Michael Van Canneyt
<michael at freepascal.org> wrote:

>>
>> It seems like in some examples one uses the transaction as follows:
>> ATransaction.StartTransaction;
>> .. do database stuff ...
>> ATransaction.Commit;
>>
>
>In general it is better to explicitly handle your transactions.
>However, if you don't do that, then SQLDB will do it for you.

So as long as there is a TSQLTransaction object hooked to the
connection and query (same transaction object) then the built-in
system will do the StartTransaction-Commit sequence in the background
if I do not explicitly code for it?


-- 
Bo Berglund
Developer in Sweden





More information about the Lazarus mailing list