Board index » delphi » Tquery and begin transaction

Tquery and begin transaction

Hi, i have a design problem,

I have a Tdatabase component and 3 Tquery component. I want to begin a
transaction when one is modify. The user take some action and and commit
(save).

My problem is that when I commit, all change in the 2 other query are
committed. How can I do committing for a query in particular and not for
all the database?

thank's

Luc C

 

Re:Tquery and begin transaction


Quote
Luc Carbonneau wrote in message <38A1CDE1.F35E7...@vmd.desjardins.com>...

>I have a Tdatabase component and 3 Tquery component. I want to begin a
>transaction when one is modify. The user take some action and and commit
>(save).

>My problem is that when I commit, all change in the 2 other query are
>committed. How can I do committing for a query in particular and not for
>all the database?

Using TQuerys uses the BDE which is limited to handling a single transaction
at a time. So the only way to avoid your problem is to not allow more than
one dataset to be in edit mode at one time.

If you're using Delphi 5 and Interbase, you can use the IBX components which
allow you to control multiple transactions concurrently.

--
Wayne Niddery - WinWright Consulting
RADBooks - http://members.home.net/wniddery/
You have a Right to Free Speech, but not the right to make me listen, nor to
use my property as a soapbox.

Other Threads