> Loop thru the records putting the records that dont match the name I am looing for 
>into another flatfile DB, and when the name I am want to
> delete is found I the just dont add that record to the new DB, then when its 
>finished, I delete the DB, rename the second one back to the
> original one, i.e. from db.tmp to db.dat etc. But I wonder if this IS the best way. 
>It does delete duplicate names too, but thats my fault..
> 
> Can anyone suggest a better way ?

Eww!
  Possibilities: 
1/ use a real DB instead.
2/ Use a record allocation structure in conjunction with data records. Ie when the
record used, a corrosponding bit in the structure is set, cleared when deleted.
Next new record writes into the first available record with a clear bit.



----------------------------------------------------------
Phil Scadden, Institute of Geological and Nuclear Sciences
41 Bell Rd South, PO Box 30368, Lower Hutt, New Zealand
Ph +64 4 5704821, fax +64 4 5704603
---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED] 
with body of "unsubscribe delphi"

Reply via email to