<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=iso-8859-1" http-equiv=Content-Type>
<META name=GENERATOR content="MSHTML 8.00.6001.18813">
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT color=#000000 size=2 face=Arial>That is what I ended up doing, works
ok enough. Such records get cleaned up in time.</FONT></DIV>
<DIV><FONT color=#000000 size=2 face=Arial></FONT> </DIV>
<DIV>John Bird<BR>JBCL<BR>Contact:<BR><A
href="mailto:johnkbird@paradise.net.nz">johnkbird@paradise.net.nz</A><BR>03-3844527,
027 4844528<BR><A
href="http://jbclnz.googlepages.com">http://jbclnz.googlepages.com</A><BR><A
href="http://www.jbcl.co.nz">http://www.jbcl.co.nz</A></DIV>
<BLOCKQUOTE
style="BORDER-LEFT: #000000 2px solid; PADDING-LEFT: 5px; PADDING-RIGHT: 0px; MARGIN-LEFT: 5px; MARGIN-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV
style="FONT: 10pt arial; BACKGROUND: #e4e4e4; font-color: black"><B>From:</B>
<A title=paul.a.norman@gmail.com href="mailto:paul.a.norman@gmail.com">Paul A
Norman</A> </DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A title=delphi@delphi.org.nz
href="mailto:delphi@delphi.org.nz">NZ Borland Developers Group - Delphi
List</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Saturday, September 05, 2009 5:08
PM</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> Re: [DUG] Setting Data File
Size</DIV>
<DIV><BR></DIV>
<DIV>Not sure if I am on the same page as you John, are you still working this
through only just saw it?</DIV>
<DIV> </DIV>
<DIV>One OS safe method - if you are using fixed record sizes, then instead of
removing a record (and repacking the file in situ) re-enter/alter the
record with a key field saying "deleted" or something.</DIV>
<DIV> </DIV>
<DIV>Then periodically when there is no file access going on run a
maintanence routine to rewrite the file to a copy not writing the deleted
records accross, then delete/backup original and rename your newly written
maintenece file as the original.</DIV>
<DIV> </DIV>
<DIV>Paul</DIV>
<DIV><BR> </DIV>
<DIV class=gmail_quote>2009/8/26 Peter Hyde <SPAN dir=ltr><<A
href="mailto:peter@webcentre.co.nz">peter@webcentre.co.nz</A>></SPAN><BR>
<BLOCKQUOTE
style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex"
class=gmail_quote>John asked:<BR>
<DIV class=im><BR>> Is there a simple way to alter the size of an
existing file -<BR>> particularly to decrease the
size?<BR><BR></DIV>Unless TFileStream has changed since I last looked in
detail, you<BR>won't find it easy.<BR><BR>I know that in similar cases I
ended up adopting the "write to temp<BR>file/rename-after" approach; I don't
know if that would suit your<BR>conditions
adequately.<BR><BR><BR>cheers,<BR>peter<BR><BR>===========================================<BR>Peter
Hyde, Development Director<BR>* <A href="http://turbonote.com/"
target=_blank>http://TurboNote.com</A> -- top-rated onscreen sticky
notes<BR>* Web development and automation: <A href="http://webcentre.co.nz/"
target=_blank>http://webcentre.co.nz</A><BR><BR><BR><BR>_______________________________________________<BR>NZ
Borland Developers Group - Delphi mailing list<BR>Post: <A
href="mailto:delphi@delphi.org.nz">delphi@delphi.org.nz</A><BR>Admin: <A
href="http://delphi.org.nz/mailman/listinfo/delphi"
target=_blank>http://delphi.org.nz/mailman/listinfo/delphi</A><BR>Unsubscribe:
send an email to <A
href="mailto:delphi-request@delphi.org.nz">delphi-request@delphi.org.nz</A>
with Subject: unsubscribe<BR></BLOCKQUOTE></DIV><BR>
<P>
<HR>
<P></P>_______________________________________________<BR>NZ Borland
Developers Group - Delphi mailing list<BR>Post: delphi@delphi.org.nz<BR>Admin:
http://delphi.org.nz/mailman/listinfo/delphi<BR>Unsubscribe: send an email to
delphi-request@delphi.org.nz with Subject:
unsubscribe</BLOCKQUOTE></BODY></HTML>