FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour append from
Posts: 102
Joined: Sat Jun 06, 2015 06:57 PM
append from
Posted: Thu May 26, 2016 04: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

Posts: 159
Joined: Wed Mar 28, 2007 01:19 PM
Re: append from
Posted: Thu May 26, 2016 04: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.

Posts: 102
Joined: Sat Jun 06, 2015 06:57 PM
Re: append from
Posted: Thu May 26, 2016 08:59 PM

I guess that's true backward compatability then!

Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
Re: append from
Posted: Wed Jun 01, 2016 02: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

Continue the discussion