From: | zoulx1982(at)163(dot)com |
---|---|
To: | pgsql-bugs(at)postgresql(dot)org |
Subject: | BUG #11266: failed to find conversion function from unknown to bigint |
Date: | 2014-08-26 06:21:10 |
Message-ID: | 20140826062110.2532.26317@wrigleys.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
The following bug has been logged on the website:
Bug reference: 11266
Logged by: zoulx1982
Email address: zoulx1982(at)163(dot)com
PostgreSQL version: 9.4beta2
Operating system: Win7
Description:
when i migrate my application from oracle to postgrs,
i encounter a query raise error "failed to find conversion function from
unknown to bigint"
the original query is very complicated, so i summarize a simple testcase:
create table t1(a varchar(10));
create table t2(x varchar(10), y bigint);
select s.*
from
(select a, null b from t1
group by a
) s
union all
select x,y from t2;--ERROR
postgres=# select version();
version
----------------------------------------------------------------
PostgreSQL 9.5devel, compiled by Visual C++ build 1600, 32-bit
(1 row)
and when i remove the "group" clause, the query works well
or if i don't use sub-query, it can also work well, i.e.
select a, null b from t1 group by a union all select x,y from t2;
and
select s.* from (select a, null b from t1) s union all select x,y from t2;
is all OK.
is there parameters to avoid the issue without changing original sql,
or doe's somebody can fix the issue later ?
thanks.
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2014-08-26 14:42:32 | Re: BUG #11266: failed to find conversion function from unknown to bigint |
Previous Message | Alvaro Herrera | 2014-08-26 04:03:28 | Re: BUG #11264: Auto vacuum wraparound job blocking everything |