Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How do program transaction within transaction
Message
 
 
To
07/06/2010 17:46:44
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP1
Miscellaneous
Thread ID:
01467775
Message ID:
01467787
Views:
36
>>>In form1 user is presented with a list of dates worked. He can chose to add a new date or edit an existing date at which point form2 (or page2) appears allowing entering values for that date. When done with form2 user can choose to save or cancel changes made. This is not a problem. It can be handled by buffering data tables and either commiting or rolling back.
>>>
>>>Problem is, I would like to also allow user to change many dates in one session and then either commit or cancel changes made to all dates including the ones just added.
>>>
>>>I believe this can be handled by transactions within a transaction but I don;t know how to do it. I am using Codemine framework. All help is appreciated.
>>>
>>>TIA,
>>>
>>>Alex
>>
>>This also can be done with TABLE buffering :-)
>>Just the final TABLEUPDATE() or TABLEREVERT() should be changed to commit all records.
>
>Thank you Borislav.
>
>All tables use table buffering. I did not mention that as user edits in form2, related records in other tables are changed and sometimes even other records in main table are affected because of crazy labor rules. For this reason I need to go back to the original question of how to do transactions within a transaction.
>
>In an older and related application designed during FoxPro DOS days we made a copy of memory variables and of some tables upon entering form2 an then restored them if user backed out, but I don;t want to do it that way in the new application.
>
>Thanks for the help,
>
>Alex

You can do nested transactions.
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform