Subject | Re: [firebird-support] Bug with character sets |
---|---|
Author | Mark Rotteveel |
Post date | 2009-05-20T11:14:33Z |
> But the (X)SQLDA does not contain N. It does however contain charset id,That is not correct. If I use UTF-8, one character can be 1 to 4 bytes. Using the buffersize and the 'max bytes per char' you will NOT be able to compute the characterlength.
> which can be used to obtain "max bytes per char", which can be used in
> combination with the buffer size specified in SQLDA to determine N.
Example:
buffer length of 4 bytes, UTF-8 (max 4 bytes per character): is this 1, 2, 3 or 4 characters? You simply don't know until you decode.
Mark
--
Neu: GMX FreeDSL Komplettanschluss mit DSL 6.000 Flatrate + Telefonanschluss für nur 17,95 Euro/mtl.!* http://dslspecial.gmx.de/freedsl-aktionspreis/?ac=OM.AD.PD003K11308T4569a