[fpc-pascal] Patch: new XML export for FCL-DB ready for inclusion, issue 19790 - includes Delphi Clientdataset
Reinier Olislagers
reinierolislagers at gmail.com
Mon Aug 15 10:56:59 CEST 2011
On 28-7-2011 9:24, michael.vancanneyt at wisa.be wrote:
> On Thu, 28 Jul 2011, Reinier Olislagers wrote:
>> On 27-7-2011 20:52, michael.vancanneyt at wisa.be wrote:
>> Code like
>>
>> ftWideString: //fixed length or at least max length string
>> begin
>> TDOMElement(ColumnNode).SetAttribute('fieldtype', 'string');
>> TDOMElement(ColumnNode).SetAttribute('WIDTH',
>>
>> UTF8Decode(string(ExportFields.Fields[ItemCounter].Field.Size)));
>> end;
Regarding the snippet above: for Unicode-enabled Delphis, using
Clientdataset savetofile as UTF8-based XML (dfXMLUTF8), what do I need
to output for a ftString:
- Field.Size (number of characters in string)
- Field.DataSize (number of bytes in string field)
As Michael indicated, it probably is Field.Size, but I'd like to have
that confirmed. (Can't seem to find any documentation on ClientDataset
XML format on Embarcadero's Delphi help at
http://docwiki.embarcadero.com/VCL/en/DBClient.TCustomClientDataSet.SaveToFile)
Thanks,
Reinier
More information about the fpc-pascal
mailing list