>>use Mytable && A Table With An Incorrect Record That Belong To A Dbc
>>begin Transaction
>>append Blank
>>brow && You See The New Record
>
>Insert a
=tableupdate()
here. That's the effective part of the transaction which you didn't run, so nothing actually happened.
>
>>end Transaction
>>brow && The New Record Is Lost !!!
>>
>>do You Have Any Workarround Avaiable ?
I don't have buffering enabled because is very much slower, (nearly 10 times to complete a transaction).
thanks anyway
I found a workarround for this problem and I hope you could use it.
Here's the example
*** You must test every table before BEGIN TRANSACTION
PPA=ADIR(PPB,LOCFILE("mytable.DBF"))
SELECT 0
USE mytable AGAIN
PPT=HEADER()+1+RECC()*RECSIZE()
IF PPB(2)<>PPT .AND. PPB(2)<>PPT-1
do error
ENDIF
USE
procedure error
** ONE ALTERNATIVE
CLOSE DATA ALL
USE MYTABLE EXCL
APPEND BLANK
DELETE
PACK
*** ANOTHER ALTERNATIVE IF YOU HAVE FOXFIX
CLOSE DATA ALL
=FIXDBF("MYTABLE.DBF",1)