From: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
---|---|
To: | pgsql-sql(at)postgresql(dot)org |
Cc: | Tomas Doran <bobtfish(at)bobtfish(dot)net>, tdoran(at)venda(dot)com |
Subject: | Re: Potential bug in postgres 8.2.4 |
Date: | 2007-05-24 11:51:15 |
Message-ID: | 200705241351.15767.peter_e@gmx.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
Am Donnerstag, 24. Mai 2007 13:20 schrieb Tomas Doran:
> CREATE TABLE testtable (
> col1 char(1),
> data text
> );
> The following queries all work:
> INSERT INTO testtable (col1, data) VALUES (3::int, 'foobarbazquux');
> SELECT * FROM testtable WHERE col1 = 3::int;
> SELECT * FROM testtable WHERE col1 IN (1);
> SELECT * FROM testtable WHERE col1 IN (1::int);
> However these querys fail on 8.2.4, but work correctly on 8.1:
> SELECT * FROM testtable WHERE col1 IN (1::int, 2::int);
> SELECT * FROM testtable WHERE col1 IN (1, 2);
All of this is strictly speaking incorrect anyway. And the queries that do
work will most likely start not working in a future version. All of this is
a gradual effort to reduce excessive automatic type casting.
I suggest you fix your application.
--
Peter Eisentraut
http://developer.postgresql.org/~petere/
From | Date | Subject | |
---|---|---|---|
Next Message | Tomas Doran | 2007-05-24 11:54:48 | Re: Potential bug in postgres 8.2.4 |
Previous Message | Marcin Stępnicki | 2007-05-24 11:34:03 | Re: Potential bug in postgres 8.2.4 |