Changeset: 5aaf3d0eaf5b for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/5aaf3d0eaf5b
Modified Files:
        sql/storage/bat/bat_logger.c
Branch: Jul2021
Log Message:

Use leftjoin instead of intersect with interchanged arguments.
We need to keep the ordering of the values the same as the ordering in
the "b3" input, so it must be the first argument to the join in the
leftjoin family.


diffs (20 lines):

diff --git a/sql/storage/bat/bat_logger.c b/sql/storage/bat/bat_logger.c
--- a/sql/storage/bat/bat_logger.c
+++ b/sql/storage/bat/bat_logger.c
@@ -1624,12 +1624,14 @@ upgrade(old_logger *lg)
                bat_destroy(b1);
                goto bailout;
        }
-       b4 = BATintersect(lg->lg->catalog_id, b3, NULL, NULL, false, false, 
BUN_NONE);
+       BAT *b2;
+       rc = BATleftjoin(&b2, &b4, b3, lg->lg->catalog_id, NULL, NULL, false, 
BUN_NONE);
        bat_destroy(b3);
-       if (b4 == NULL) {
+       if (rc != GDK_SUCCEED) {
                bat_destroy(b1);
                goto bailout;
        }
+       bat_destroy(b2);
        struct canditer ci;
        canditer_init(&ci, lg->lg->catalog_bid, b1);
        const oid *cbids;
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to