On Sat, 16 Aug 2003, Joe Conway wrote:

> I stumbled across this behavior today and it seems strange if not a bug:
>
> -- this seems wrong
> vsconf=# create table foo (f1 char(1));
> CREATE TABLE
> vsconf=# insert into foo values(' ');
> INSERT 9002011 1
> vsconf=# select ascii(f1) from foo;
>   ascii
> -------
>       0
> (1 row)

I think the reason for this is that ascii is actually
defined ascii(text) and the conversion from char(n)
to text now drops the trailing spaces.


---------------------------(end of broadcast)---------------------------
TIP 9: the planner will ignore your desire to choose an index scan if your
      joining column's datatypes do not match

Reply via email to