From: Tomas Doran <bobtfish@bobtfish.net>
To: pgsql-sql@postgresql.org
Cc: tdoran@venda.com
Subject: Potential bug in postgres 8.2.4
Date: Thu, 24 May 2007 12:20:54 +0100
Message-ID: <3D2864D1-BF64-4609-B307-1C70A4FE503F@bobtfish.net> (raw)
I'm not sure if this is a bug, or not - but it looks like one to me.
if you say:
CREATE TABLE testtable (
col1 char(1),
data text
);
INSERT INTO testtable (col1, data) VALUES ('1', 'foobar');
INSERT INTO testtable (col1, data) VALUES ('2', 'foobarbaz');
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);
I could understand if the behavior was the same for single element IN
clauses, and multiple element IN clauses - however as their behavior
is different, and it used to work in 8.1....
Cheers
Tom
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: bobtfish@bobtfish.net, tdoran@venda.com
Subject: Re: Potential bug in postgres 8.2.4
In-Reply-To: <3D2864D1-BF64-4609-B307-1C70A4FE503F@bobtfish.net>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox