append from

append from

Postby dtussman » Thu May 26, 2016 4:05 pm

Anyone else notice that when you APPEND FROM a file the resulting file includes deleted records from the source file and the deleted records are now undeleted, even if you Set Deleted on? That is something you need to beware of
dtussman
 
Posts: 97
Joined: Sat Jun 06, 2015 6:57 pm

Re: append from

Postby Euclides » Thu May 26, 2016 4:31 pm

Hi dtussman.
Clipper does the same long time ago.
The funny thing is: "APPEND FROM <file> FOR !deleted()" does not work either. (of course)
Regards, Euclides.
User avatar
Euclides
 
Posts: 156
Joined: Wed Mar 28, 2007 1:19 pm

Re: append from

Postby dtussman » Thu May 26, 2016 8:59 pm

I guess that's true backward compatability then!
dtussman
 
Posts: 97
Joined: Sat Jun 06, 2015 6:57 pm

Re: append from

Postby James Bott » Wed Jun 01, 2016 2:20 pm

David,

From the book CA Clipper 5.3:

Deleted records: If DELETED is OFF, deleted records in
<xcFile> are APPENDed to the current database file and retain their
deleted status. If DELETED is ON, however, none of the deleted
<xcFile> records are APPENDed.


I always do a SET DELETED ON at the beginning of all my programs. If for some reason I need to see deleted records (very rare), then I turn it off, then back on at the end of the routine (think encapsulation).

James
FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
User avatar
James Bott
 
Posts: 4840
Joined: Fri Nov 18, 2005 4:52 pm
Location: San Diego, California, USA


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 59 guests