Changeset: 57e7d4e09f92 for MonetDB URL: https://dev.monetdb.org/hg/MonetDB/rev/57e7d4e09f92 Modified Files: sql/server/rel_unnest.c sql/test/SQLancer/Tests/sqlancer22.test Branch: default Log Message:
Merged with Jan2022 diffs (43 lines): diff --git a/sql/server/rel_unnest.c b/sql/server/rel_unnest.c --- a/sql/server/rel_unnest.c +++ b/sql/server/rel_unnest.c @@ -1162,7 +1162,7 @@ push_up_groupby(mvc *sql, sql_rel *rel, if (exp_has_freevar(sql, e)) rel_bind_var(sql, rel->l, e); } - r->exps = list_merge(r->exps, a, (fdup)NULL); + r->exps = list_distinct(list_merge(r->exps, a, (fdup)NULL), (fcmp)exp_equal, (fdup)NULL); if (!r->r) { if (id) r->r = list_append(sa_list(sql->sa), exp_ref(sql, id)); diff --git a/sql/test/SQLancer/Tests/sqlancer22.test b/sql/test/SQLancer/Tests/sqlancer22.test --- a/sql/test/SQLancer/Tests/sqlancer22.test +++ b/sql/test/SQLancer/Tests/sqlancer22.test @@ -252,4 +252,27 @@ SELECT 1 FROM t0 WHERE 5 <= ALL(SELECT 2 ---- statement ok +create or replace view vx(vc0, vc1) as (select 10, 2) + +query I nosort +SELECT vx.vc1 <> ALL(SELECT x.x) FROM vx JOIN (SELECT 1) AS x(x) ON vx.vc1 <> ALL(SELECT vx.vc1 FROM t0) AND (SELECT FALSE FROM t0) +---- + +query I nosort +SELECT vx.vc1 <> ALL(SELECT x.x FROM t0) FROM vx JOIN (SELECT 1) AS x(x) ON vx.vc1 <> ALL(SELECT vx.vc1 FROM t0) AND (SELECT FALSE FROM t0) +---- + +query I nosort +SELECT 1 FROM vx JOIN (SELECT 1) AS x(x) ON vx.vc1 <> ALL(SELECT vx.vc1 FROM t0) AND (SELECT FALSE FROM t0) +---- + +query I nosort +SELECT 1 FROM vx WHERE vx.vc1 <> ALL(SELECT vx.vc1 FROM t0) AND (SELECT FALSE FROM t0) +---- + +query I nosort +SELECT 1 FROM (SELECT DISTINCT c0 FROM rt0) vt(vc1) WHERE (1) IN (SELECT 2 FROM rt0 GROUP BY rt0.c0, vt.vc1) +---- + +statement ok ROLLBACK _______________________________________________ checkin-list mailing list checkin-list@monetdb.org https://www.monetdb.org/mailman/listinfo/checkin-list