Ma Siva Kumar <siva@leatherlink.net> writes:
> On Tuesday 11 Nov 2003 9:02 pm, Dennis Gearon wrote:
>> This is something I've been wondereing about for quite awhile - does
>> pgsql measure bytes or chars when using UTF for varchars. It looks like
>> bytes, which is counter intuitive.
The measurement is certainly in characters, in 7.3 and later. In 7.2 it
was in characters if you'd enabled multibyte. Once upon a time it was
in bytes, but I don't believe that applies to Ma Siva Kumar's problem.
> 在您的系统中直接获 (entered through html form processed by php script) shows as
> 在您的系统 when seen with psql. Anything more
> than this is rejected for lack of space (the size is varchar(100)
I think there is some confusion between you and the database about
character set encoding. Double check what the database encoding is
(psql \l will tell you). And double check what the system thinks the
client-side encoding is ("show client_encoding" and/or \encoding).
regards, tom lane