Re: BUG #3413: character string or multibyte character to "char"

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Toru SHIMOGAKI" <shimogaki(dot)toru(at)oss(dot)ntt(dot)co(dot)jp>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #3413: character string or multibyte character to "char"
Date: 2007-06-26 14:08:02
Message-ID: 18255.1182866882@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

"Toru SHIMOGAKI" <shimogaki(dot)toru(at)oss(dot)ntt(dot)co(dot)jp> writes:
> When a character string or a multibyte character is inserted to "char"
> column, no error occurs. Is this a bug?

That's the historical behavior of the datatype, and given that it's
been like that since Berkeley days, changing it seems ill-advised.
If you want a column that behaves sanely for multibyte data, use
char(1).

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2007-06-26 14:19:01 Re: REVOKE CREATE does not work on default tablespace
Previous Message Zdenek Kotala 2007-06-26 12:29:40 Re: REVOKE CREATE does not work on default tablespace