Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to update or revert some records
Message
 
To
24/02/2007 05:58:02
Mk Sharma
Shrishti Solutions
Mumbai, India
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
01198522
Message ID:
01198527
Views:
8
>i have new and old both records in buffer.
>
>can i do like this
>
>
>SELECT YourTable
>SCAN for code=101
>   if recno()<0  && buffered new records
>      IF Id == [101-1]
>         IF TABLEUPDATE(0,.t.,[YourTable])
>            ***
>         ENDIF
>      ELSE
>         TableRevert(.f.,[YourTable])
>      ENDIF
>   else && buffered old records
>      IF Id == [101-1]
>         IF TABLEUPDATE(0,.t.,[YourTable])
>            ***
>         ENDIF
>      ELSE
>         delete
>         IF TABLEUPDATE(0,.t.,[YourTable])
>            ***
>         ENDIF
>      ENDIF
>   endif
>ENDSCAN
>
>
>
>warm regards,
>mk.


:-)) (Deja vu)
DELETE FROM MyTable WHERE Id # [101-1]
TABLEUPDATE(1, .t., [MyTable])
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform