Changeset: aaaf8847adc2 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=aaaf8847adc2
Modified Files:
        sql/backends/monet5/rel_bin.c
Branch: Jun2020
Log Message:

corrected check for nil/null values in insert_check_ukey


diffs (20 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
@@ -3796,13 +3796,13 @@ insert_check_ukey(backend *be, list *ins
                        stmt *sel = NULL;
 
                        /* remove any nils as in stmt_order NULL = NULL, 
instead of NULL != NULL */
-                       if ((k->type == ukey) && stmt_has_null(col)) {
-
+                       if (k->type == ukey) {
                                for (m = k->columns->h; m; m = m->next) {
                                        sql_kc *c = m->data;
                                        stmt *cs = list_fetch(inserts, 
c->c->colnr);
 
-                                       sel = stmt_selectnonil(be, cs, sel);
+                                       if (stmt_has_null(cs))
+                                               sel = stmt_selectnonil(be, cs, 
sel);
                                }
                        }
                        /* implementation uses sort key check */
_______________________________________________
checkin-list mailing list
checkin-list@monetdb.org
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to