Page 1 of 1

Transactions

Posted: 03.11.2013, 16:13
by sfxcc
I have a masterTable and a detail table on postgresql, i need to inset mastertable line and the the details lines.

How can i do this two tables if on fail rollback ? cached updates is for own table how can i do both be on same commit ?

This to avoid convert tables to sql text because then work ... any change to be with zquery components?

Re: Transactions

Posted: 04.11.2013, 21:43
by EgonHugeist
Hi Sergio,

Use ChachedUpdates for the TZDataSet descendants. TZConnection.AutoCommit schould be False.

Than use the TZDataSet.Options := TZDataSet.Options + [doUpdateMasterFirst].