Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Information regarding the database engine of VFP8
Message
From
04/03/2003 10:02:28
 
 
To
04/03/2003 09:47:18
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00760786
Message ID:
00760871
Views:
12
Hi,
Yes, I used to read your and wiki corruption that prevent corruption. I have do the "most" thing to prevent it.
Any way, it could be poow design as you mention, but.. how to consider as good and poor design?
I always use
*---Update/Insert 
BEGIN TRANSACTION
IF llRollBack AND NOT TABLEUPDATE(.T., .F., "Sales")
    llRollBack = .T.
ENDIF

BEGIN TRANSACTION
IF llRollBack AND NOT TABLEUPDATE(.T., .F., "SalesDetails")
    llRollBack = .T.
ENDIF

BEGIN TRANSACTION
IF llRollBack AND NOT TABLEUPDATE(.T., .F., "Stock")
    llRollBack = .T.
ENDIF

....
IF llRollBack
    AERROR(laError)
    ROLLBACK
    TABLEREVERT(.T., "Sales")
    ....
ELSE
    END TRANSACTION
    FLUSH
ENDIF
You could refer to thread #748117.

Thank you
I am not the most powerful man in this world.
I am not the worst man in this world either.
I just as same as all of you.
I still need to learn from my mistakes...
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform