[fpc-devel] TFieldDef.Size vs TField.Size

Martin Schreiber mse00000 at gmail.com
Thu Feb 24 09:07:31 CET 2011

On Thursday 24 February 2011 08:02:20 LacaK wrote:
> So also here we can see, that FieldDef.Size is expected to be number of
> characters not bytes.
> So IMHO logical conclusion will be say, that TFieldDef.Size for string
> fields has same menaing as Field.Size, so it is number of characters
> (so documentation is wrong in this case ... also fast test in Delphi
> shows, that FieldDef.Size=Field.Size=number of characters)
Agreed. In MSEgui tmsestringfield.size is the maximum allowed character count 
for the field. 0 = no limit. tmsebufdataset stores string data as 
UnicodeString instead to use a fixed record layout. With some databases it is 
a little bit tricky to get the field size in characters instead in bytes.
In case you don't know MSEgui:



More information about the fpc-devel mailing list