Closed GoogleCodeExporter closed 9 years ago
PostgreSQL throws the exception:
ERROR: column "node.name" must appear in the GROUP BY clause or be used in an
aggregate function
Original comment by thomas.t...@gmail.com
on 21 Dec 2010 at 7:23
I can reproduce the problem, and I have a simpler test case now:
drop table test;
create table test(id int);
insert into test values(1), (2), (4);
select a.id, a.id in(select 4) x
from test a, test b where a.id in (b.id, b.id - 1);
select a.id, a.id in(select 4) x
from test a, test b where a.id in (b.id, b.id - 1)
group by a.id;
I don't know what the problem is so far, but I hope I can solve it in the next
release.
Thanks a lot for your help!
Original comment by thomas.t...@gmail.com
on 21 Dec 2010 at 8:25
Another test case (more like your test case):
drop table role;
drop table menu;
create table menu(id int primary key, lft int, rgt int);
insert into menu values(8, 21, 40), (9, 22, 23), (10, 51, 70);
select a.id, b.id, a.id in(select 10) as visible
from menu as a, menu as b
where a.lft between b.lft and b.rgt;
select a.id, a.id = 10 as visible
from menu as a, menu as b
where a.lft between b.lft and b.rgt group by a.id order by a.id;
Original comment by thomas.t...@gmail.com
on 21 Dec 2010 at 8:28
Fixed in version 1.3.149
Original comment by thomas.t...@gmail.com
on 10 Jan 2011 at 7:22
Original issue reported on code.google.com by
conanca2...@gmail.com
on 17 Dec 2010 at 2:38