[fpc-pascal] How to save a huge XML?
Michael Van Canneyt
michael at freepascal.org
Tue Jun 18 16:03:20 CEST 2013
On Tue, 18 Jun 2013, Marcos Douglas wrote:
>> Ideas? Maybe do what Antonio Fortuny said before?
>> Yep, a text file: assign, reset, append, close. I use an own build logger
>> facility (for historical reasons) but I wonder whether Lazarus (or FPC)
>> does not have such a logger component.
> Ok, thank you.
Keep the file open between writes.
Otherwise you'll notice a serious performance penalty.
You can always call Flush() to make sure the content of
a buffer was written to disc.
Thus, in case of a crash, the XML file will contain all log entries,
but will not be well-formed XML.
More information about the fpc-pascal