Changeset: 2202f6e3e129 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/2202f6e3e129
Modified Files:
        sql/backends/monet5/rel_bin.c
        sql/test/BugTracker-2026/Tests/All
Branch: default
Log Message:

fixed issue #7987, ie fixed code generation for anti conjunctives.


diffs (35 lines):

diff --git a/sql/backends/monet5/rel_bin.c b/sql/backends/monet5/rel_bin.c
--- a/sql/backends/monet5/rel_bin.c
+++ b/sql/backends/monet5/rel_bin.c
@@ -710,6 +710,7 @@ exp_bin_conjunctive(backend *be, sql_exp
        node *n;
        stmt *sel1 = NULL, *s = NULL;
        int anti = is_anti(e);
+       bool first = true;
 
        sel1 = sel;
        for (n = l->h; n; n = n->next) {
@@ -754,9 +755,10 @@ exp_bin_conjunctive(backend *be, sql_exp
                                predicate = stmt_const(be, predicate, 
stmt_bool(be, 1));
                                s = stmt_uselect(be, predicate, s, cmp_equal, 
sel1, anti, is_semantics(c));
                        }
-               } else if (reduce && anti && sel1) {
+               } else if (!first && reduce && anti && sel1) {
                        s = stmt_tunion(be, s, sel1);
                }
+               first = false;
                sel1 = s;
        }
        if (sel1 && sel1->nrcols == 0 && left) {
diff --git a/sql/test/BugTracker-2026/Tests/All 
b/sql/test/BugTracker-2026/Tests/All
--- a/sql/test/BugTracker-2026/Tests/All
+++ b/sql/test/BugTracker-2026/Tests/All
@@ -170,7 +170,7 @@ KNOWNFAIL?7982-range-current-row-bug
 7984-exists-select-count-bug
 KNOWNFAIL?7985-qualify-row_number-over-bug
 KNOWNFAIL?7986-right-function-bug
-KNOWNFAIL?7987-where-null-bug
+7987-where-null-bug
 KNOWNFAIL?7989-window-avg-bug
 KNOWNFAIL?7990-rank-filter-bug
 7991-group_concat-null-separator-bug
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to