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

Function next_value_for is "unsafe".


diffs (47 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
@@ -2804,10 +2804,9 @@ bl_postversion(void *Store, void *Lg)
                        return GDK_FAIL;
                }
                /* the functions we need to change to FALSE */
-               BAT *funcs = COLnew(0, TYPE_str, 2, TRANSIENT);
+               BAT *funcs = COLnew(0, TYPE_str, 1, TRANSIENT);
                if (funcs == NULL ||
-                       BUNappend(funcs, "sqlrand", false) != GDK_SUCCEED ||
-                       BUNappend(funcs, "next_value", false) != GDK_SUCCEED) {
+                       BUNappend(funcs, "sqlrand", false) != GDK_SUCCEED) {
                        bat_destroy(cands);
                        bat_destroy(func_se);
                        bat_destroy(func_func);
@@ -2815,7 +2814,7 @@ bl_postversion(void *Store, void *Lg)
                        return GDK_FAIL;
                }
                /* select * from sys.functions where schema_id = 2000 and func 
in (...) */
-               b = BATintersect(func_func, funcs, cands, NULL, false, false, 
4);
+               b = BATintersect(func_func, funcs, cands, NULL, false, false, 
1);
                bat_destroy(funcs);
                if (b == NULL) {
                        bat_destroy(cands);
@@ -2876,10 +2875,11 @@ bl_postversion(void *Store, void *Lg)
                        return GDK_FAIL;
                }
                /* the functions we need to change to TRUE */
-               funcs = COLnew(0, TYPE_str, 4, TRANSIENT);
+               funcs = COLnew(0, TYPE_str, 5, TRANSIENT);
                if (funcs == NULL ||
                        BUNappend(funcs, "copy_from", false) != GDK_SUCCEED ||
                        BUNappend(funcs, "importTable", false) != GDK_SUCCEED ||
+                       BUNappend(funcs, "next_value", false) != GDK_SUCCEED ||
                        BUNappend(funcs, "update_schemas", false) != 
GDK_SUCCEED ||
                        BUNappend(funcs, "update_tables", false) != 
GDK_SUCCEED) {
                        bat_destroy(cands);
@@ -2889,7 +2889,7 @@ bl_postversion(void *Store, void *Lg)
                        return GDK_FAIL;
                }
                /* select * from sys.functions where schema_id = 2000 and func 
in (...) */
-               b = BATintersect(func_func, funcs, cands, NULL, false, false, 
4);
+               b = BATintersect(func_func, funcs, cands, NULL, false, false, 
7);
                bat_destroy(funcs);
                bat_destroy(cands);
                bat_destroy(func_func);
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to