On 31/03/2015 20:24, Mark Rotteveel [email protected] 
[firebird-support] wrote:
> The problem is mainly that when the connection character set is UTF8, 
> and the field character set is anything other than NONE or OCTETS, the 
> server will return the field as UTF8. The length of a field in UTF8 is 
> 4 * the declared length (which is the maximum number of bytes 
> required). It is up to the client (isql, or a driver like the ibase 
> PHP driver, Jaybird, etc), to correctly interpret a field of length 32 
> bytes in utf8 to a string of 8 characters; unfortunately not all 
> clients/drivers do this, so they will act as if it is string of 32 
> characters. Mark 

So my temporary fudge to trim() the result is actually the best that can 
be done, and it's a good thing I'm not expecting the presence or absence 
of trailing spaces in VARCHAR fields to be significant, it looks like.

-- 
Tim Ward



------------------------------------

------------------------------------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Visit http://www.firebirdsql.org and click the Documentation item
on the main (top) menu.  Try FAQ and other links from the left-side menu there.

Also search the knowledgebases at http://www.ibphoenix.com/resources/documents/ 

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
------------------------------------

Yahoo Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/firebird-support/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/firebird-support/join
    (Yahoo! ID required)

<*> To change settings via email:
    [email protected] 
    [email protected]

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo Groups is subject to:
    https://info.yahoo.com/legal/us/yahoo/utos/terms/

Reply via email to