MonetDB: check - merge with default
Changeset: 9d1fac6dfbb4 for MonetDB URL: https://dev.monetdb.org/hg/MonetDB/rev/9d1fac6dfbb4 Branch: check Log Message: merge with default diffs (118 lines): diff --git a/monetdb5/modules/atoms/str.c b/monetdb5/modules/atoms/str.c --- a/monetdb5/modules/atoms/str.c +++ b/monetdb5/modules/atoms/str.c @@ -1910,60 +1910,62 @@ STRselect(MalStkPtr stk, InstrPtr pci, throw(MAL, fname, SQLSTATE(HY013) MAL_MALLOC_FAIL); } - BATiter bi = bat_iterator(b); - QryCtx *qry_ctx = MT_thread_get_qry_ctx(); - if (icase) - str_cmp = str_icmp; - oid *vals = Tloc(bn, 0); - const int klen = str_strlen(key); - if (ci.tpe == cand_dense) { - if (with_strimps_anti) - scanloop(strNil(v) || str_cmp(v, key, klen) == 0, canditer_next_dense); - else if (anti) - scanloop(!strNil(v) && str_cmp(v, key, klen) != 0, canditer_next_dense); - else - scanloop(!strNil(v) && str_cmp(v, key, klen) == 0, canditer_next_dense); - } else { - if (with_strimps_anti) - scanloop(strNil(v) || str_cmp(v, key, klen) == 0, canditer_next); - else if (anti) - scanloop(!strNil(v) && str_cmp(v, key, klen) != 0, canditer_next); - else - scanloop(!strNil(v) && str_cmp(v, key, klen) == 0, canditer_next); - } - bat_iterator_end(); - TIMEOUT_CHECK(qry_ctx, HANDLE_TIMEOUT(qry_ctx)); - - if (!msg) { - BATsetcount(bn, rcnt); - bn->tsorted = true; - bn->trevsorted = bn->batCount <= 1; - bn->tkey = true; - bn->tnil = false; - bn->tnonil = true; - bn->tseqbase = rcnt == 0 ? - 0 : rcnt == 1 ? - *(const oid *) Tloc(bn, 0) : rcnt == ci.ncand && ci.tpe == cand_dense ? ci.hseq : oid_nil; - - if (with_strimps_anti) { - BAT *rev; - if (old_s) { - rev = BATdiffcand(old_s, bn); + if (!strNil(key)) { + BATiter bi = bat_iterator(b); + QryCtx *qry_ctx = MT_thread_get_qry_ctx(); + if (icase) + str_cmp = str_icmp; + oid *vals = Tloc(bn, 0); + const int klen = str_strlen(key); + if (ci.tpe == cand_dense) { + if (with_strimps_anti) + scanloop(strNil(v) || str_cmp(v, key, klen) == 0, canditer_next_dense); + else if (anti) + scanloop(!strNil(v) && str_cmp(v, key, klen) != 0, canditer_next_dense); + else + scanloop(!strNil(v) && str_cmp(v, key, klen) == 0, canditer_next_dense); + } else { + if (with_strimps_anti) + scanloop(strNil(v) || str_cmp(v, key, klen) == 0, canditer_next); + else if (anti) + scanloop(!strNil(v) && str_cmp(v, key, klen) != 0, canditer_next); + else + scanloop(!strNil(v) && str_cmp(v, key, klen) == 0, canditer_next); + } + bat_iterator_end(); + TIMEOUT_CHECK(qry_ctx, HANDLE_TIMEOUT(qry_ctx)); + + if (!msg) { + BATsetcount(bn, rcnt); + bn->tsorted = true; + bn->trevsorted = bn->batCount <= 1; + bn->tkey = true; + bn->tnil = false; + bn->tnonil = true; + bn->tseqbase = rcnt == 0 ? + 0 : rcnt == 1 ? + *(const oid *) Tloc(bn, 0) : rcnt == ci.ncand && ci.tpe == cand_dense ? ci.hseq : oid_nil; + + if (with_strimps_anti) { + BAT *rev; + if (old_s) { + rev = BATdiffcand(old_s, bn); #ifndef NDEBUG - BAT *is = BATintersectcand(old_s, bn); - if (is) { - assert(is->batCount == bn->batCount); - BBPreclaim(is); - } - assert(rev->batCount == old_s->batCount - bn->batCount); + BAT *is = BATintersectcand(old_s, bn); + if (is) { + assert(is->batCount == bn->batCount); + BBPreclaim(is); + } +
MonetDB: check - merge with default
Changeset: b1dfe5e93d80 for MonetDB URL: https://dev.monetdb.org/hg/MonetDB/rev/b1dfe5e93d80 Branch: check Log Message: merge with default diffs (truncated from 4449 to 300 lines): diff --git a/gdk/gdk_string.c b/gdk/gdk_string.c --- a/gdk/gdk_string.c +++ b/gdk/gdk_string.c @@ -7211,421 +7211,421 @@ static const char *const valtab[] = { [102] = "~", [103] = "''", [104] = "", - [105] = ";", - [106] = "AMD", - [107] = "M", - [108] = "ue", - [109] = "X", - [110] = "SS", - [111] = "LL", - [112] = "ll", - [113] = "--", - [114] = "\"", - [115] = ",,", - [116] = "+", - [117] = "..", - [118] = "...", - [119] = "``", - [120] = "```", - [121] = "<", - [122] = ">", - [123] = "!!", - [124] = "??", - [125] = "?!", - [126] = "!?", - [127] = "&", - [128] = "0", - [129] = "4", - [130] = "5", - [131] = "6", - [132] = "7", - [133] = "8", - [134] = "9", - [135] = "=", - [136] = "(", - [137] = ")", - [138] = "CE", - [139] = "C=", - [140] = "Cr", - [141] = "Fr.", - [142] = "L.", - [143] = "Pts", - [144] = "Rs", - [145] = "KRW", - [146] = "ILS", - [147] = "Dong", - [148] = "EUR", - [149] = "GRD", - [150] = "PHP", - [151] = "UAH", - [152] = "KZT", - [153] = "INR", - [154] = "TL", - [155] = "RUB", - [156] = "GEL", - [157] = "a/c", - [158] = "a/s", - [159] = "c/o", - [160] = "c/u", - [161] = "No", - [162] = "Q", - [163] = "Rx", - [164] = "SM", - [165] = "TEL", - [166] = "(TM)", - [167] = "FAX", - [168] = " 1/7 ", - [169] = " 1/9 ", - [170] = " 1/10 ", - [171] = " 1/3 ", - [172] = " 2/3 ", - [173] = " 1/5 ", - [174] = " 2/5 ", - [175] = " 3/5 ", - [176] = " 4/5 ", - [177] = " 1/6 ", - [178] = " 5/6 ", - [179] = " 1/8 ", - [180] = " 3/8 ", - [181] = " 5/8 ", - [182] = " 7/8 ", - [183] = " 1/ ", - [184] = "II", - [185] = "III", - [186] = "IV", - [187] = "VI", - [188] = "VII", - [189] = "VIII", - [190] = "IX", - [191] = "XI", - [192] = "XII", - [193] = "ii", - [194] = "iii", - [195] = "iv", - [196] = "vi", - [197] = "vii", - [198] = "viii", - [199] = "ix", - [200] = "xi", - [201] = "xii", - [202] = " 0/3 ", - [203] = "<-", - [204] = "->", - [205] = "<->", - [206] = "!<->", - [207] = "!<=", - [208] = "!<=>", - [209] = "!=>", - [210] = "<=", - [211] = "=>", - [212] = "<=>", - [213] = "\\", - [214] = "*", - [215] = "||", - [216] = "!~", - [217] = "!~-", - [218] = "!~=", - [219] = "!~~", - [220] = "!=", - [221] = "!==", - [222] = ">=", - [223] = "!<", - [224] = "!>", - [225] = "!>=", - [226] = "!<~", - [227] = "!>~", - [228] = "!<>", - [229] = "!><", - [230] = "<<<", - [231] = ">>>", - [232] = "NUL", - [233] = "SOH", - [234] = "STX", - [235] = "ETX", - [236] = "EOT", - [237] = "ENQ", - [238] = "ACK", - [239] = "BEL", - [240] = "BS", - [241] = "HT", - [242] = "LF", - [243] = "VT", - [244] = "FF", - [245] = "CR", - [246] = "SO", - [247] = "SI", - [248] = "DLE", - [249] = "DC1", - [250] = "DC2", - [251] = "DC3", - [252] = "DC4", - [253] = "NAK", - [254] = "SYN", - [255] = "ETB", - [256] = "CAN", - [257] = "EM", - [258] = "SUB", - [259] = "ESC", - [260] = "FS", - [261] = "GS", - [262] = "RS", - [263] = "US", - [264] = "SP", - [265] = "DEL", - [266] = "NL", - [267] = "(1)", - [268] = "(2)", - [269] = "(3)", - [270] = "(4)", - [271] = "(5)", - [272] = "(6)", - [273] = "(7)", - [274] = "(8)", - [275] = "(9)", - [276] = "(10)", - [277] = "(11)", - [278] = "(12)", - [279] = "(13)", - [280] = "(14)", - [281] = "(15)", - [282] = "(16)", - [283] = "(17)", - [284] = "(18)", - [285] = "(19)", - [286] = "(20)", - [287] = "1.", - [288] = "2.", - [289] = "3.", - [290] = "4.", - [291] = "5.", - [292] = "6.", - [293] = "7.", - [294] = "8.", - [295] = "9.", - [296] = "10.", - [297] = "11.", - [298] = "12.", - [299] = "13.", - [300] = "14.", - [301] = "15.", - [302] = "16.", - [303] = "17.", - [304] = "18.", - [305] = "19.", - [306] = "20.",
MonetDB: check - merge with default
Changeset: 1c112b6b273c for MonetDB URL: https://dev.monetdb.org/hg/MonetDB/rev/1c112b6b273c Branch: check Log Message: merge with default diffs (truncated from 619 to 300 lines): diff --git a/gdk/gdk_logger.c b/gdk/gdk_logger.c --- a/gdk/gdk_logger.c +++ b/gdk/gdk_logger.c @@ -1038,6 +1038,7 @@ log_read_types_file(logger *lg, FILE *fp { int id = 0; char atom_name[IDLENGTH]; + bool seen_geom = false; /* scanf should use IDLENGTH somehow */ while (fscanf(fp, "%d,%63s\n", , atom_name) == 2) { @@ -1049,9 +1050,17 @@ log_read_types_file(logger *lg, FILE *fp GDKerror("unknown type in log file '%s'\n", atom_name); return GDK_FAIL; } + seen_geom |= strcmp(atom_name, "mbr") == 0 || strcmp(atom_name, "wkb") == 0; lg->type_id[i] = (int8_t) id; lg->type_nr[id < 0 ? 256 + id : id] = i; } +#ifdef HAVE_GEOM + if (!seen_geom && ATOMindex("mbr") > 0) { + GDKerror("incompatible database: server supports GEOM, but database does not\n"); + return GDK_FAIL; + } +#endif + (void) seen_geom; return GDK_SUCCEED; } @@ -1802,7 +1811,8 @@ bm_subcommit(logger *lg, logged_range *p cleanup++; if (lids[p] == -1) continue; - if (BUNappend(dcatalog, &(oid){p}, true) != GDK_SUCCEED) { + if (BUNfnd(dcatalog, &(oid){p}) == BUN_NONE && + BUNappend(dcatalog, &(oid){p}, true) != GDK_SUCCEED) { while (BATcount(dcatalog) > dcnt) { if (BUNdelete(dcatalog, BATcount(dcatalog) - 1) != GDK_SUCCEED) { TRC_CRITICAL(WAL, "delete after failed append failed\n"); diff --git a/gdk/gdk_string.c b/gdk/gdk_string.c --- a/gdk/gdk_string.c +++ b/gdk/gdk_string.c @@ -1477,153 +1477,155 @@ GDKanalytical_str_group_concat(BAT *r, B * Only for the casefold table, if the converted codepoint is negative, * it is actually an escape into the specialcase table. The absolute * value is the index. */ + +/* These tables were created using the code in unicaseconvtabs.py */ static const char *const specialcase[] = { NULL, - "ss", - "i\xCC\x87", - "\xCA\xBCn", - "j\xCC\x8C", - "\xCE\xB9\xCC\x88\xCC\x81", - "\xCF\x85\xCC\x88\xCC\x81", - "\xD5\xA5\xD6\x82", - "h\xCC\xB1", - "t\xCC\x88", - "w\xCC\x8A", - "y\xCC\x8A", - "a\xCA\xBE", - "\xCF\x85\xCC\x93", - "\xCF\x85\xCC\x93\xCC\x80", - "\xCF\x85\xCC\x93\xCC\x81", - "\xCF\x85\xCC\x93\xCD\x82", - "\xE1\xBC\x80\xCE\xB9", - "\xE1\xBC\x81\xCE\xB9", - "\xE1\xBC\x82\xCE\xB9", - "\xE1\xBC\x83\xCE\xB9", - "\xE1\xBC\x84\xCE\xB9", - "\xE1\xBC\x85\xCE\xB9", - "\xE1\xBC\x86\xCE\xB9", - "\xE1\xBC\x87\xCE\xB9", - "\xE1\xBC\xA0\xCE\xB9", - "\xE1\xBC\xA1\xCE\xB9", - "\xE1\xBC\xA2\xCE\xB9", - "\xE1\xBC\xA3\xCE\xB9", - "\xE1\xBC\xA4\xCE\xB9", - "\xE1\xBC\xA5\xCE\xB9", - "\xE1\xBC\xA6\xCE\xB9", - "\xE1\xBC\xA7\xCE\xB9", - "\xE1\xBD\xA0\xCE\xB9", - "\xE1\xBD\xA1\xCE\xB9", - "\xE1\xBD\xA2\xCE\xB9", - "\xE1\xBD\xA3\xCE\xB9", - "\xE1\xBD\xA4\xCE\xB9", - "\xE1\xBD\xA5\xCE\xB9", - "\xE1\xBD\xA6\xCE\xB9", - "\xE1\xBD\xA7\xCE\xB9", - "\xE1\xBD\xB0\xCE\xB9", - "\xCE\xB1\xCE\xB9", - "\xCE\xAC\xCE\xB9", - "\xCE\xB1\xCD\x82", - "\xCE\xB1\xCD\x82\xCE\xB9", - "\xE1\xBD\xB4\xCE\xB9", - "\xCE\xB7\xCE\xB9", - "\xCE\xAE\xCE\xB9", - "\xCE\xB7\xCD\x82", - "\xCE\xB7\xCD\x82\xCE\xB9", - "\xCE\xB9\xCC\x88\xCC\x80", - "\xCE\xB9\xCD\x82", - "\xCE\xB9\xCC\x88\xCD\x82", - "\xCF\x85\xCC\x88\xCC\x80", - "\xCF\x81\xCC\x93", - "\xCF\x85\xCD\x82", - "\xCF\x85\xCC\x88\xCD\x82", - "\xE1\xBD\xBC\xCE\xB9", - "\xCF\x89\xCE\xB9", - "\xCF\x8E\xCE\xB9", - "\xCF\x89\xCD\x82", - "\xCF\x89\xCD\x82\xCE\xB9", - "ff", - "fi", - "fl", - "ffi", - "ffl", - "st", - "\xD5\xB4\xD5\xB6", - "\xD5\xB4\xD5\xA5", - "\xD5\xB4\xD5\xAB", - "\xD5\xBE\xD5\xB6", - "\xD5\xB4\xD5\xAD", - "SS", - "FF", - "FI", - "FL", - "FFI", - "FFL", - "ST", - "\xD4\xB5\xD5\x92", - "\xD5\x84\xD5\x86", - "\xD5\x84\xD4\xB5", - "\xD5\x84\xD4\xBB", - "\xD5\x8E\xD5\x86", - "\xD5\x84\xD4\xBD", - "\xCA\xBCN", - "\xCE\x99\xCC\x88\xCC\x81", - "\xCE\xA5\xCC\x88\xCC\x81", - "J\xCC\x8C", - "H\xCC\xB1", - "T\xCC\x88", - "W\xCC\x8A", - "Y\xCC\x8A", - "A\xCA\xBE", -
MonetDB: check - merge with default
Changeset: 2e2b4a44301c for MonetDB URL: https://dev.monetdb.org/hg/MonetDB/rev/2e2b4a44301c Branch: check Log Message: merge with default diffs (truncated from 309 to 300 lines): diff --git a/monetdb5/modules/mal/pcre.c b/monetdb5/modules/mal/pcre.c --- a/monetdb5/modules/mal/pcre.c +++ b/monetdb5/modules/mal/pcre.c @@ -63,7 +63,7 @@ struct RE { * byte and don't deal with multibyte encodings (such as UTF-8). */ static inline bool -re_is_pattern_properly_escaped(const char *pat, unsigned char esc) +mnre_is_pattern_properly_escaped(const char *pat, unsigned char esc) { bool escaped = false; @@ -94,7 +94,7 @@ is_strcmpable(const char *pat, const cha /* Match regular expression by comparing bytes. */ static inline bool -re_match(const char *restrict s, const struct RE *restrict pattern) +mnre_match(const char *restrict s, const struct RE *restrict pattern) { const struct RE *r; @@ -142,14 +142,14 @@ re_match(const char *restrict s, const s * we need to backtrack, so use recursion; here we know we * have the %, look for an _ in the rest of the pattern * (note %_ and _% are equivalent and is taken care of by -* the pattern construction in re_create) */ +* the pattern construction in mnre_create) */ for (const struct RE *p = r->n; p; p = p->n) { if (p->skip != 0) { struct RE pat = *r; pat.search = false; pat.skip = 0; do { - if (re_match(s, )) + if (mnre_match(s, )) return true; do s++; @@ -213,7 +213,7 @@ re_match(const char *restrict s, const s } static void -re_destroy(struct RE *p) +mnre_destroy(struct RE *p) { if (p) { GDKfree(p->k); @@ -235,7 +235,7 @@ re_destroy(struct RE *p) * the first. */ static struct RE * -re_create(const char *pat, bool caseignore, uint32_t esc) +mnre_create(const char *pat, bool caseignore, uint32_t esc) { struct RE *r = GDKmalloc(sizeof(struct RE)), *n = r; bool escaped = false; @@ -312,7 +312,7 @@ re_create(const char *pat, bool caseigno *q = 0; return r; bailout: - re_destroy(r); + mnre_destroy(r); return NULL; } @@ -1131,7 +1131,7 @@ choose_like_path(bool *use_re, bool *use if (strNil(pat) || strNil(esc)) { *empty = true; } else { - if (!re_is_pattern_properly_escaped(pat, (unsigned char) *esc)) + if (!mnre_is_pattern_properly_escaped(pat, (unsigned char) *esc)) throw(MAL, "pcre.sql2pcre", SQLSTATE(22019) ILLEGAL_ARGUMENT ": (I)LIKE pattern must not end with escape character"); @@ -1169,16 +1169,16 @@ PCRElike_imp(bit *ret, const char *const *ret = *isens ? GDKstrcasecmp(*s, *pat) == 0 : strcmp(*s, *pat) == 0; } else { - if (!(re = re_create(*pat, *isens, (unsigned char) **esc))) + if (!(re = mnre_create(*pat, *isens, (unsigned char) **esc))) res = createException(MAL, "pcre.like4", SQLSTATE(HY013) MAL_MALLOC_FAIL); else - *ret = re_match(*s, re); + *ret = mnre_match(*s, re); } } if (re) - re_destroy(re); + mnre_destroy(re); return res; } @@ -1202,11 +1202,11 @@ PCREnotlike(bit *ret, const char *const } static inline str -re_like_build(struct RE **re, const char *pat, bool caseignore, +mnre_like_build(struct RE **re, const char *pat, bool caseignore, bool use_strcmp, uint32_t esc) { if (!use_strcmp) { - if (!(*re = re_create(pat, caseignore, esc))) + if (!(*re = mnre_create(pat, caseignore, esc))) return createException(MAL, "pcre.re_like_build", SQLSTATE(HY013) MAL_MALLOC_FAIL); } @@ -1214,7 +1214,7 @@ re_like_build(struct RE **re, const char } static inline bit -re_like_proj_apply(const char *s, const struct RE *restrict re, +mnre_like_proj_apply(const char *s, const struct RE *restrict re, const char *pat,
MonetDB: check - merge with default
Changeset: 3ac1eb089295 for MonetDB URL: https://dev.monetdb.org/hg/MonetDB/rev/3ac1eb089295 Modified Files: sql/server/rel_select.c Branch: check Log Message: merge with default diffs (60 lines): diff --git a/sql/server/rel_select.c b/sql/server/rel_select.c --- a/sql/server/rel_select.c +++ b/sql/server/rel_select.c @@ -4744,6 +4744,23 @@ rel_rankop(sql_query *query, sql_rel **r char *uaname = SA_NEW_ARRAY(sql->ta, char, strlen(aname) + 1); return sql_error(sql, 02, SQLSTATE(42000) "%s: window functions cannot be nested", toUpperCopy(uaname, aname)); } + if (window_function->token == SQL_UNOP || window_function->token == SQL_OP) { + window_function->token = SQL_NOP; + dn->next->next->data.lval = dlist_append_symbol(sql->sa, dlist_create( sql->sa ), dn->next->next->data.sym); /* make a list */ + } + if (window_function->token == SQL_BINOP) { + window_function->token = SQL_NOP; + dn->next->next->data.lval = dlist_append_symbol(sql->sa, dlist_append_symbol(sql->sa, dlist_create( sql->sa ), dn->next->next->data.sym), dn->next->next->next->data.sym); /* make a list */ + dn->next->next->next = dn->next->next->next->next; /* skip second arg */ + } + if (window_function->token == SQL_AGGR) + dn->next->next->data.lval = dlist_append_symbol(sql->sa, dlist_create( sql->sa ), dn->next->next->data.sym); /* make a list */ + if (window_function->token == SQL_NOP) + window_function->token = SQL_AGGR; + if (window_function->token != SQL_RANK && window_function->token != SQL_AGGR) { + char *uaname = SA_NEW_ARRAY(sql->ta, char, strlen(aname) + 1); + return sql_error(sql, 02, SQLSTATE(42000) "SELECT: window function '%s' unknown", toUpperCopy(uaname, aname)); + } /* window operations are only allowed in the projection */ if (!is_sql_sel(f)) @@ -4814,7 +4831,7 @@ rel_rankop(sql_query *query, sql_rel **r } } else { /* aggregation function call */ distinct = dn->next->data.i_val; - for (dargs = dn->next->next ; dargs && dargs->data.sym ; dargs = dargs->next) { + for (dargs = dn->next->next->data.lval->h ; dargs && dargs->data.sym ; dargs = dargs->next) { exp_kind ek = {type_value, card_column, FALSE}; sql_subtype *empty = sql_bind_localtype("void"), *bte = sql_bind_localtype("bte"); diff --git a/sql/test/BugTracker-2024/Tests/7514-wrong-window-function.test b/sql/test/BugTracker-2024/Tests/7514-wrong-window-function.test new file mode 100644 --- /dev/null +++ b/sql/test/BugTracker-2024/Tests/7514-wrong-window-function.test @@ -0,0 +1,11 @@ +statement error SELECT: no such window function 'wrong_function'(tinyint, tinyint, tinyint) +select + wrong_function(col1, col2, col3) over w +from + (select 0 as col1, 1 as col2, 2 as col3) t window w as (partition by col1) + +statement error SELECT: identifier 'wrong_column' unknown +select + wrong_function(col1, col2, wrong_column) over w +from + (select 0 as col1, 1 as col2, 2 as col3) t window w as (partition by col1) diff --git a/sql/test/BugTracker-2024/Tests/All b/sql/test/BugTracker-2024/Tests/All --- a/sql/test/BugTracker-2024/Tests/All +++ b/sql/test/BugTracker-2024/Tests/All @@ -58,3 +58,4 @@ field-arg-error-Bug-7506 7511-password-hash-missing-error 7512-concurrent-globaltmp-instantiate-crash 7513-uri-authority-parse-issue +7514-wrong-window-function ___ checkin-list mailing list -- checkin-list@monetdb.org To unsubscribe send an email to checkin-list-le...@monetdb.org
MonetDB: check - merge with default
Changeset: 91250c27a94f for MonetDB URL: https://dev.monetdb.org/hg/MonetDB/rev/91250c27a94f Modified Files: sql/backends/monet5/rel_bin.c sql/server/rel_rel.h sql/server/rel_select.c sql/server/sql_parser.y sql/storage/store.c Branch: check Log Message: merge with default diffs (truncated from 36794 to 300 lines): diff --git a/.hgtags b/.hgtags --- a/.hgtags +++ b/.hgtags @@ -825,3 +825,5 @@ dcc8c702e685a4faf21ccf663028d1bc3d1165d1 dcc8c702e685a4faf21ccf663028d1bc3d1165d1 Dec2023_SP1_release d656785f49ee62c19705722aa6b7c171904c64d5 Dec2023_7 d656785f49ee62c19705722aa6b7c171904c64d5 Dec2023_SP2_release +9a694c41042503a22d6c92aeab5bc4ca1912b62e Dec2023_9 +9a694c41042503a22d6c92aeab5bc4ca1912b62e Dec2023_SP3_release diff --git a/ChangeLog b/ChangeLog --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,21 @@ # ChangeLog file for devel # This file is updated with Maddlog +* Wed May 8 2024 Sjoerd Mullender +- The shared library (.dll aka .so files) now have the version number + as part of the name. This should allow the building of compatibility + versions that can be installed in parallel to the latest version. +- Some of the Debian/Ubuntu packages have been renamed. The old monetdb5 + names have been changed to plain monetdb, and libmonetdb5-server-* + packages have been renamed monetdb-*. +- The names of some of the provided RPM files have been changed. + References to the old MonetDB5 name have been removed. All packages + are now just MonetDB. + +* Wed May 8 2024 Niels Nes +- Add support for select exp, count(*) group by 1 order by 1; ie. using + numeric references Added support for group by all and order by all. The + later is ordering on all columns of the selection. The group by all + finds all expressions from the selections which aren't aggregations + and groups on those. All can also be replaced by '*'. + diff --git a/MonetDB.spec b/MonetDB.spec --- a/MonetDB.spec +++ b/MonetDB.spec @@ -8,8 +8,12 @@ # Copyright August 2008 - 2023 MonetDB B.V.; # Copyright 1997 - July 2008 CWI. -%global name MonetDB %global version 11.50.0 + +%bcond_with compat + +%global name MonetDB%{?with_compat:%version} + %{!?buildno: %global buildno %(date +%Y%m%d)} # Use bcond_with to add a --with option; i.e., "without" is default. @@ -57,7 +61,7 @@ # available. However, the geos library is available in the Extra # Packages for Enterprise Linux (EPEL). %if %{fedpkgs} && (0%{?rhel} != 7) && (0%{?rhel} != 8) -# By default create the MonetDB-geom-MonetDB5 package on Fedora and RHEL 7 +# By default create the MonetDB-geom package on Fedora and RHEL 7 %bcond_without geos %endif @@ -91,7 +95,7 @@ Group: Applications/Databases License: MPL-2.0 URL: https://www.monetdb.org/ BugURL: https://github.com/MonetDB/MonetDB/issues -Source: https://www.monetdb.org/downloads/sources/Dec2023-SP2/%{name}-%{version}.tar.bz2 +Source: https://www.monetdb.org/downloads/sources/Dec2023-SP3/MonetDB-%{version}.tar.bz2 # The Fedora packaging document says we need systemd-rpm-macros for # the _unitdir and _tmpfilesdir macros to exist; however on RHEL 7 @@ -117,7 +121,9 @@ BuildRequires: unixODBC-devel BuildRequires: readline-devel %else BuildRequires: pkgconfig(bzip2) +%if %{without compat} BuildRequires: pkgconfig(odbc) +%endif BuildRequires: pkgconfig(readline) %endif %if %{with fits} @@ -154,8 +160,8 @@ BuildRequires: pkgconfig(libR) # BuildRequires: pkgconfig(valgrind)# -DWITH_VALGRIND=ON %if (0%{?fedora} >= 22) -Recommends: %{name}-SQL-server5%{?_isa} = %{version}-%{release} -Recommends: MonetDB5-server%{?_isa} = %{version}-%{release} +Recommends: %{name}-SQL%{?_isa} = %{version}-%{release} +Recommends: %{name}-server%{?_isa} = %{version}-%{release} Suggests: %{name}-client%{?_isa} = %{version}-%{release} %endif @@ -167,8 +173,8 @@ accelerators. It also has an SQL front This package contains the core components of MonetDB in the form of a single shared library. If you want to use MonetDB, you will certainly -need this package, but you will also need at least the MonetDB5-server -package, and most likely also %{name}-SQL-server5, as well as one or +need this package, but you will also need at least the %{name}-server +package, and most likely also %{name}-SQL, as well as one or more client packages. %ldconfig_scriptlets @@ -176,8 +182,9 @@ more client packages. %files %license COPYING %defattr(-,root,root) -%{_libdir}/libbat.so.* +%{_libdir}/libbat*.so.* +%if %{without compat} %package devel Summary: MonetDB development files Group: Applications/Databases @@ -202,8 +209,9 @@ functionality of MonetDB. %{_includedir}/monetdb/mstring.h %exclude %{_includedir}/monetdb/monetdbe.h %{_includedir}/monetdb/monet*.h -%{_libdir}/libbat.so +%{_libdir}/libbat*.so %{_libdir}/pkgconfig/monetdb-gdk.pc +%endif %package stream Summary: MonetDB stream library @@ -223,8 +231,9 @@ various other components. %files stream %license COPYING
MonetDB: check - merge with default
Changeset: 17c946f67a6a for MonetDB URL: https://dev.monetdb.org/hg/MonetDB/rev/17c946f67a6a Modified Files: sql/backends/monet5/rel_bin.c sql/include/sql_catalog.h sql/server/sql_parser.y sql/storage/store.c Branch: check Log Message: merge with default diffs (truncated from 979 to 300 lines): diff --git a/gdk/gdk_bbp.c b/gdk/gdk_bbp.c --- a/gdk/gdk_bbp.c +++ b/gdk/gdk_bbp.c @@ -1711,6 +1711,9 @@ BBPjson_upgrade(json_storage_conversion const char *nme; nme = ATOMunknown_name(b->ttype); + int tt = ATOMindex(nme); + if (tt >= 0) + b->ttype = tt; if (strcmp(nme, "json") != 0) continue; } else if (b->ttype != JSON_type) { @@ -4065,34 +4068,41 @@ BBPsync(int cnt, bat *restrict subcommit if (lock) MT_lock_set((bid)); } - if (subcommit) { + BAT *b = BBP_desc(bid); + if (subcommit && b->ttype != TYPE_void) { /* move any tail/theap files we find for this bat that * are in the BACKUP directory to the SUBCOMMIT * directory */ char fname[16]; /* plenty big enough */ - if (snprintf(fname, sizeof(fname), "%o", i) < 16) { + if (snprintf(fname, sizeof(fname), "%o", (unsigned) bid) < 16) { /* the snprintf never fails, any of the * below may fail */ - if (GDKmove(0, BAKDIR, fname, "tail", SUBDIR, fname, "tail", false) == GDK_SUCCEED) - TRC_DEBUG(BAT_, "moved %s.tail from %s to %s\n", + uint8_t stpe = ATOMstorage(b->ttype); + if ((b->ttype != TYPE_str || b->twidth >= 8) && + GDKmove(0, BAKDIR, fname, "tail", SUBDIR, fname, "tail", false) == GDK_SUCCEED) + TRC_DEBUG(IO_, "moved %s.tail from %s to %s\n", fname, BAKDIR, SUBDIR); - if (GDKmove(0, BAKDIR, fname, "tail1", SUBDIR, fname, "tail1", false) == GDK_SUCCEED) - TRC_DEBUG(BAT_, "moved %s.tail1 from %s to %s\n", + if (stpe == TYPE_str && + GDKmove(0, BAKDIR, fname, "tail1", SUBDIR, fname, "tail1", false) == GDK_SUCCEED) + TRC_DEBUG(IO_, "moved %s.tail1 from %s to %s\n", fname, BAKDIR, SUBDIR); - if (GDKmove(0, BAKDIR, fname, "tail2", SUBDIR, fname, "tail2", false) == GDK_SUCCEED) - TRC_DEBUG(BAT_, "moved %s.tail2 from %s to %s\n", + if (stpe == TYPE_str && b->twidth >= 2 && + GDKmove(0, BAKDIR, fname, "tail2", SUBDIR, fname, "tail2", false) == GDK_SUCCEED) + TRC_DEBUG(IO_, "moved %s.tail2 from %s to %s\n", fname, BAKDIR, SUBDIR); #if SIZEOF_VAR_T == 8 - if (GDKmove(0, BAKDIR, fname, "tail4", SUBDIR, fname, "tail4", false) == GDK_SUCCEED) - TRC_DEBUG(BAT_, "moved %s.tail4 from %s to %s\n", + if (stpe == TYPE_str && b->twidth >= 4 && + GDKmove(0, BAKDIR, fname, "tail4", SUBDIR, fname, "tail4", false) == GDK_SUCCEED) + TRC_DEBUG(IO_, "moved %s.tail4 from %s to %s\n", fname, BAKDIR, SUBDIR); #endif - if (GDKmove(0, BAKDIR, fname, "theap", SUBDIR, fname, "theap", false) == GDK_SUCCEED) - TRC_DEBUG(BAT_, "moved %s.theap from %s to %s\n", + if (ATOMvarsized(b->ttype) && + GDKmove(0, BAKDIR, fname, "theap", SUBDIR, fname, "theap", false) == GDK_SUCCEED) + TRC_DEBUG(IO_, "moved %s.theap from %s to %s\n", fname, BAKDIR, SUBDIR); } } - BAT *b = dirty_bat(, subcommit != NULL); + b = dirty_bat(, subcommit != NULL); if (i <= 0) ret = GDK_FAIL; else if (BBP_status(bid) & BBPEXISTING && diff --git a/sql/backends/monet5/rel_bin.c b/sql/backends/monet5/rel_bin.c ---
MonetDB: check - merge with default
Changeset: c14db874309b for MonetDB URL: https://dev.monetdb.org/hg/MonetDB/rev/c14db874309b Branch: check Log Message: merge with default diffs (288 lines): diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -48,7 +48,12 @@ jobs: ref: ${{ github.ref }} - name: install pymonetdb cryptography -run: pip3 install pymonetdb cryptography +run: pip3 install --user --upgrade pymonetdb cryptography +if: runner.os != 'macOS' + + - name: install pymonetdb cryptography +run: pip3 install --user --break-system-packages --upgrade pymonetdb cryptography +if: runner.os == 'macOS' - name: make MonetDB on linux run: | @@ -83,7 +88,23 @@ jobs: -DBISON_EXECUTABLE=/usr/local/opt/bison/bin/bison \ -DCMAKE_SUMMARY=ON make install -j3 -if: runner.os == 'macOS' +if: runner.os == 'macOS' && runner.arch == 'x64' + + - name: make MonetDB on macos +run: | + mkdir build + cd build + cmake .. \ +-DCMAKE_INSTALL_PREFIX=$HOME/MDB \ +-DPY3INTEGRATION=OFF \ +-DRINTEGRATION=OFF \ +-DCMAKE_BUILD_TYPE=Release \ +-DASSERT=OFF \ +-DCMAKE_C_COMPILER=${{ matrix.c_compiler }} \ +-DBISON_EXECUTABLE=/opt/homebrew/opt/bison/bin/bison \ +-DCMAKE_SUMMARY=ON + make install -j3 +if: runner.os == 'macOS' && runner.arch == 'arm64' - name: choco packages run: | diff --git a/clients/odbc/driver/SQLConnect.c b/clients/odbc/driver/SQLConnect.c --- a/clients/odbc/driver/SQLConnect.c +++ b/clients/odbc/driver/SQLConnect.c @@ -251,7 +251,7 @@ MNDBConnect(ODBCDbc *dbc, } if (mid == NULL || mapi_error(mid)) { /* Client unable to establish connection */ - addDbcError(dbc, "08001", NULL, 0); + addDbcError(dbc, "08001", mid ? mapi_error_str(mid) : NULL, 0); rc = SQL_ERROR; /* clean up */ if (mid) diff --git a/gdk/gdk_bbp.c b/gdk/gdk_bbp.c --- a/gdk/gdk_bbp.c +++ b/gdk/gdk_bbp.c @@ -4065,6 +4065,33 @@ BBPsync(int cnt, bat *restrict subcommit if (lock) MT_lock_set((bid)); } + if (subcommit) { + /* move any tail/theap files we find for this bat that +* are in the BACKUP directory to the SUBCOMMIT +* directory */ + char fname[16]; /* plenty big enough */ + if (snprintf(fname, sizeof(fname), "%o", i) < 16) { + /* the snprintf never fails, any of the +* below may fail */ + if (GDKmove(0, BAKDIR, fname, "tail", SUBDIR, fname, "tail", false) == GDK_SUCCEED) + TRC_DEBUG(BAT_, "moved %s.tail from %s to %s\n", + fname, BAKDIR, SUBDIR); + if (GDKmove(0, BAKDIR, fname, "tail1", SUBDIR, fname, "tail1", false) == GDK_SUCCEED) + TRC_DEBUG(BAT_, "moved %s.tail1 from %s to %s\n", + fname, BAKDIR, SUBDIR); + if (GDKmove(0, BAKDIR, fname, "tail2", SUBDIR, fname, "tail2", false) == GDK_SUCCEED) + TRC_DEBUG(BAT_, "moved %s.tail2 from %s to %s\n", + fname, BAKDIR, SUBDIR); +#if SIZEOF_VAR_T == 8 + if (GDKmove(0, BAKDIR, fname, "tail4", SUBDIR, fname, "tail4", false) == GDK_SUCCEED) + TRC_DEBUG(BAT_, "moved %s.tail4 from %s to %s\n", + fname, BAKDIR, SUBDIR); +#endif + if (GDKmove(0, BAKDIR, fname, "theap", SUBDIR, fname, "theap", false) == GDK_SUCCEED) + TRC_DEBUG(BAT_, "moved %s.theap from %s to %s\n", + fname, BAKDIR, SUBDIR); + } + } BAT *b = dirty_bat(, subcommit != NULL); if (i <= 0) ret = GDK_FAIL; diff --git a/monetdb5/modules/mal/pcre.c b/monetdb5/modules/mal/pcre.c --- a/monetdb5/modules/mal/pcre.c +++ b/monetdb5/modules/mal/pcre.c @@ -733,6 +733,7 @@ single_replace(pcre *pcre_code, pcre_ext int offset = 0; int len_result = 0; int addlen; + int empty_match_correction = 0; char *tmp; do { @@ -740,7 +741,12 @@ single_replace(pcre *pcre_code, pcre_ext
MonetDB: check - merge with default
Changeset: 94f72926051f for MonetDB URL: https://dev.monetdb.org/hg/MonetDB/rev/94f72926051f Modified Files: sql/storage/store.c Branch: check Log Message: merge with default diffs (truncated from 1070 to 300 lines): diff --git a/cmake/monetdb-defines.cmake b/cmake/monetdb-defines.cmake --- a/cmake/monetdb-defines.cmake +++ b/cmake/monetdb-defines.cmake @@ -85,6 +85,7 @@ function(monetdb_configure_defines) check_symbol_exists("getopt_long" "getopt.h" HAVE_GETOPT_LONG) cmake_pop_check_state() check_function_exists("getrlimit" HAVE_GETRLIMIT) + check_function_exists("gettid" HAVE_GETTID) check_function_exists("gettimeofday" HAVE_GETTIMEOFDAY) check_function_exists("getuid" HAVE_GETUID) check_symbol_exists("gmtime_r" "time.h" HAVE_GMTIME_R) diff --git a/common/utils/matomic.h b/common/utils/matomic.h --- a/common/utils/matomic.h +++ b/common/utils/matomic.h @@ -18,7 +18,6 @@ * The following operations are defined: * ATOMIC_VAR_INIT -- initializer for the variable (not necessarily atomic!); * ATOMIC_INIT -- initialize the variable (not necessarily atomic!); - * ATOMIC_DESTROY -- destroy the variable * ATOMIC_GET -- return the value of a variable; * ATOMIC_SET -- set the value of a variable; * ATOMIC_XCG -- set the value of a variable, return original value; @@ -114,7 +113,6 @@ typedef unsigned long ATOMIC_BASE_TYPE; #endif #define ATOMIC_INIT(var, val) atomic_init(var, (ATOMIC_BASE_TYPE) (val)) -#define ATOMIC_DESTROY(var)((void) 0) #define ATOMIC_GET(var)((ATOMIC_BASE_TYPE) *(var)) #define ATOMIC_SET(var, val) (*(var) = (ATOMIC_BASE_TYPE) (val)) #define ATOMIC_XCG(var, val) atomic_exchange(var, (ATOMIC_BASE_TYPE) (val)) @@ -173,7 +171,6 @@ typedef __declspec(align(8)) volatile AT #define ATOMIC_VAR_INIT(val) (val) #define ATOMIC_INIT(var, val) (*(var) = (val)) -#define ATOMIC_DESTROY(var)((void) 0) #if SIZEOF_SIZE_T == 8 @@ -276,7 +273,6 @@ typedef volatile ATOMIC_BASE_TYPE ATOMIC #define ATOMIC_VAR_INIT(val) (val) #define ATOMIC_INIT(var, val) (*(var) = (val)) -#define ATOMIC_DESTROY(var)((void) 0) #define ATOMIC_GET(var)((ATOMIC_BASE_TYPE) __atomic_load_n(var, __ATOMIC_SEQ_CST)) #define ATOMIC_SET(var, val) __atomic_store_n(var, (ATOMIC_BASE_TYPE) (val), __ATOMIC_SEQ_CST) diff --git a/gdk/gdk_align.c b/gdk/gdk_align.c --- a/gdk/gdk_align.c +++ b/gdk/gdk_align.c @@ -258,6 +258,7 @@ BATmaterialize(BAT *b, BUN cap) .farmid = BBPselectfarm(b->batRole, TYPE_oid, offheap), .parentid = b->batCacheid, .dirty = true, + .refs = ATOMIC_VAR_INIT(1), }; settailname(tail, BBP_physical(b->batCacheid), TYPE_oid, 0); if (HEAPalloc(tail, cap, sizeof(oid)) != GDK_SUCCEED) { @@ -273,7 +274,6 @@ BATmaterialize(BAT *b, BUN cap) for (p = 0; p < q; p++) x[p] = t++; } - ATOMIC_INIT(>refs, 1); /* point of no return */ MT_lock_set(>theaplock); assert((ATOMIC_GET(>theap->refs) & HEAPREFS) > 0); diff --git a/gdk/gdk_bat.c b/gdk/gdk_bat.c --- a/gdk/gdk_bat.c +++ b/gdk/gdk_bat.c @@ -74,6 +74,7 @@ BATcreatedesc(oid hseq, int tt, bool hea *h = (Heap) { .farmid = BBPselectfarm(role, tt, offheap), .dirty = true, + .refs = ATOMIC_VAR_INIT(1), }; if (ATOMneedheap(tt)) { @@ -84,6 +85,7 @@ BATcreatedesc(oid hseq, int tt, bool hea *vh = (Heap) { .farmid = BBPselectfarm(role, tt, varheap), .dirty = true, + .refs = ATOMIC_VAR_INIT(1), }; } } @@ -124,13 +126,11 @@ BATcreatedesc(oid hseq, int tt, bool hea if (bn->theap) { bn->theap->parentid = bn->batCacheid; - ATOMIC_INIT(>theap->refs, 1); const char *nme = BBP_physical(bn->batCacheid); settailname(bn->theap, nme, tt, width); if (bn->tvheap) { bn->tvheap->parentid = bn->batCacheid; - ATOMIC_INIT(>tvheap->refs, 1); strconcat_len(bn->tvheap->filename, sizeof(bn->tvheap->filename), nme, ".theap", NULL); @@ -603,6 +603,7 @@ BATclear(BAT *b, bool force) .parentid = b->tvheap->parentid, .dirty = true, .hasfile = b->tvheap->hasfile, + .refs = ATOMIC_VAR_INIT(1), }; strcpy_len(th->filename, b->tvheap->filename, sizeof(th->filename)); if (ATOMheap(b->ttype, th, 0) != GDK_SUCCEED) {
MonetDB: check - merge with default
Changeset: b9e1b9936232 for MonetDB URL: https://dev.monetdb.org/hg/MonetDB/rev/b9e1b9936232 Modified Files: sql/server/sql_mvc.c sql/storage/store.c Branch: check Log Message: merge with default diffs (truncated from 1294 to 300 lines): diff --git a/.hgtags b/.hgtags --- a/.hgtags +++ b/.hgtags @@ -824,3 +824,4 @@ 95d8feaa1167b5ba87bd99253c3f4e62ebf528a1 dcc8c702e685a4faf21ccf663028d1bc3d1165d1 Dec2023_5 dcc8c702e685a4faf21ccf663028d1bc3d1165d1 Dec2023_SP1_release d656785f49ee62c19705722aa6b7c171904c64d5 Dec2023_7 +d656785f49ee62c19705722aa6b7c171904c64d5 Dec2023_SP2_release diff --git a/MonetDB.spec b/MonetDB.spec --- a/MonetDB.spec +++ b/MonetDB.spec @@ -151,7 +151,6 @@ BuildRequires: pkgconfig(libR) # BuildRequires: pkgconfig(gdal)# -DSHP=ON # BuildRequires: pkgconfig(netcdf) # -DNETCDF=ON # BuildRequires: pkgconfig(proj)# -DWITH_PROJ=ON -# BuildRequires: pkgconfig(snappy) # -DWITH_SNAPPY=ON # BuildRequires: pkgconfig(valgrind)# -DWITH_VALGRIND=ON %if (0%{?fedora} >= 22) @@ -868,7 +867,6 @@ sed -i 's/1\.2/1.1/' misc/selinux/monetd -DWITH_PCRE=ON \ -DWITH_PROJ=OFF \ -DWITH_READLINE=ON \ --DWITH_SNAPPY=OFF \ -DWITH_VALGRIND=OFF \ -DWITH_XML2=ON \ -DWITH_ZLIB=ON @@ -895,9 +893,6 @@ install -d -m 0775 %{buildroot}%{_locals install -d -m 0775 %{buildroot}%{_rundir}/monetdb # remove unwanted stuff -# .la files -rm -f %{buildroot}%{_libdir}/*.la -rm -f %{buildroot}%{_libdir}/monetdb5/*.la rm -f %{buildroot}%{_libdir}/monetdb5/lib_opt_sql_append.so rm -f %{buildroot}%{_libdir}/monetdb5/lib_microbenchmark*.so rm -f %{buildroot}%{_libdir}/monetdb5/lib_udf*.so diff --git a/README.rst b/README.rst --- a/README.rst +++ b/README.rst @@ -69,8 +69,8 @@ CINTEGRATIONEnable support for C CMAKE_SUMMARY Show a summary of the cmake configuration (for debug purposes, default=OFF) CMAKE_UNITTESTS Build and run the unittest for the build system (default=OFF) FITSEnable support for FITS -GEOMEnable support for geom module -INT128 Enable support for 128-bit integers +GEOMEnable support for geom module (using libgeos library) +INT128 Enable support for 128-bit integers (if compiler supports them) NETCDF Enable support for netcdf ODBCCompile the MonetDB ODBC driver PY3INTEGRATION Enable support for Python 3 integration into MonetDB @@ -82,7 +82,9 @@ TESTING Enable support for t WITH_BZ2Include bz2 support WITH_CMOCKA Include cmocka support (default=OFF) WITH_CURL Include curl support +WITH_LZ4Include lz4 support WITH_LZMA Include lzma support +WITH_OPENSSLInclude TLS support (secure client/server connection) WITH_PCRE Include pcre support WITH_PROJ Include proj support WITH_READLINE Include readline support @@ -98,27 +100,27 @@ On Fedora, the following packages are re ``bison``, ``cmake``, ``gcc``, ``pkgconf``, ``python3``. The following packages are optional but recommended: -``bzip2-devel``, ``pcre-devel``, ``readline-devel``, -``xz-devel``, ``zlib-devel``. +``bzip2-devel``, ``lz4-devel``, ``openssl-devel``, ``pcre-devel``, +``readline-devel``, ``xz-devel``, ``zlib-devel``. The following packages are optional: ``cfitsio-devel``, ``gdal-devel``, ``geos-devel``, ``libasan``, -``libcurl-devel``, ``libxml2-devel``, ``netcdf-devel``, ``proj-devel``, -``python3-devel``, ``python3-numpy``, ``R-core-devel``, -``unixODBC-devel``, ``valgrind-devel``. +``libcmocka-devel``, ``libcurl-devel``, ``libxml2-devel``, +``netcdf-devel``, ``proj-devel``, ``python3-devel``, ``python3-numpy``, +``R-core-devel``, ``unixODBC-devel``, ``valgrind-devel``. On Ubuntu and Debian the following packages are required: ``bison``, ``cmake``, ``gcc``, ``pkg-config``, ``python3``. The following packages are optional but recommended: -``libbz2-dev``, ``libpcre3-dev``, ``libreadline-dev``, -``liblzma-dev``, ``zlib1g-dev``. +``libbz2-dev``, ``liblz4-dev``, ``libpcre3-dev``, ``libreadline-dev``, +``liblzma-dev``, ``libssl-dev``, ``zlib1g-dev``. The following packages are optional: -``libasan5``, ``libcfitsio-dev``, ``libcurl4-gnutls-dev``, -``libgdal-dev``, ``libgeos-dev``, ``libnetcdf-dev``, ``libproj-dev``, -``libxml2-dev``, ``python3-dev``, ``python3-numpy``, ``r-base-dev``, -``unixodbc-dev``, ``valgrind``. +``libasan5``, ``libcfitsio-dev``, ``libcmocka-dev``, +``libcurl4-gnutls-dev``, ``libgdal-dev``, ``libgeos-dev``, +``libnetcdf-dev``, ``libproj-dev``, ``libxml2-dev``, ``python3-dev``, +``python3-numpy``, ``r-base-dev``, ``unixodbc-dev``, ``valgrind``. ``cmake`` must be at least version 3.12, ``python`` must be at least version 3.5. diff --git a/clients/Tests/exports.stable.out b/clients/Tests/exports.stable.out --- a/clients/Tests/exports.stable.out +++
MonetDB: check - merge with default
Changeset: aad96fbaf536 for MonetDB URL: https://dev.monetdb.org/hg/MonetDB/rev/aad96fbaf536 Modified Files: sql/backends/monet5/rel_bin.c sql/include/sql_catalog.h sql/server/rel_schema.c sql/server/sql_mvc.c sql/storage/sql_storage.h sql/storage/store.c Branch: check Log Message: merge with default diffs (truncated from 2471 to 300 lines): diff --git a/clients/Tests/MAL-signatures.test b/clients/Tests/MAL-signatures.test --- a/clients/Tests/MAL-signatures.test +++ b/clients/Tests/MAL-signatures.test @@ -25330,122 +25330,62 @@ SQLvar_pop; return the variance population of groups batsql window_bound -pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:bat[:bte]):bat[:oid] -SQLwindow_bound; -computes window ranges for each row -batsql -window_bound -pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:bat[:dbl]):bat[:oid] +pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:bat?[:bte]):bat[:oid] SQLwindow_bound; computes window ranges for each row batsql window_bound -pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:bat[:flt]):bat[:oid] -SQLwindow_bound; -computes window ranges for each row -batsql -window_bound -pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:bat[:int]):bat[:oid] -SQLwindow_bound; -computes window ranges for each row -batsql -window_bound -pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:bat[:lng]):bat[:oid] +pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:bat?[:dbl]):bat[:oid] SQLwindow_bound; computes window ranges for each row batsql window_bound -pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:bat[:sht]):bat[:oid] -SQLwindow_bound; -computes window ranges for each row -batsql -window_bound -pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:bte):bat[:oid] +pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:bat?[:flt]):bat[:oid] SQLwindow_bound; computes window ranges for each row batsql window_bound -pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:dbl):bat[:oid] +pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:bat?[:int]):bat[:oid] SQLwindow_bound; computes window ranges for each row batsql window_bound -pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:flt):bat[:oid] -SQLwindow_bound; -computes window ranges for each row -batsql -window_bound -pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:int):bat[:oid] -SQLwindow_bound; -computes window ranges for each row -batsql -window_bound -pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:lng):bat[:oid] +pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:bat?[:lng]):bat[:oid] SQLwindow_bound; computes window ranges for each row batsql window_bound -pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:sht):bat[:oid] -SQLwindow_bound; -computes window ranges for each row -batsql -window_bound -pattern batsql.window_bound(X_0:bat[:bit], X_1:bat[:any_1], X_2:int, X_3:int, X_4:int, X_5:bat[:bte]):bat[:oid] +pattern batsql.window_bound(X_0:bat[:any_1], X_1:int, X_2:int, X_3:int, X_4:bat?[:sht]):bat[:oid] SQLwindow_bound; computes window ranges for each row batsql window_bound -pattern batsql.window_bound(X_0:bat[:bit], X_1:bat[:any_1], X_2:int, X_3:int, X_4:int, X_5:bat[:dbl]):bat[:oid] +pattern batsql.window_bound(X_0:bat[:bit], X_1:bat[:any_1], X_2:int, X_3:int, X_4:int, X_5:bat?[:bte]):bat[:oid] SQLwindow_bound; computes window ranges for each row batsql window_bound -pattern batsql.window_bound(X_0:bat[:bit], X_1:bat[:any_1], X_2:int, X_3:int, X_4:int, X_5:bat[:flt]):bat[:oid] -SQLwindow_bound; -computes window ranges for each row -batsql -window_bound -pattern batsql.window_bound(X_0:bat[:bit], X_1:bat[:any_1], X_2:int, X_3:int, X_4:int, X_5:bat[:int]):bat[:oid] -SQLwindow_bound; -computes window ranges for each row -batsql -window_bound -pattern batsql.window_bound(X_0:bat[:bit], X_1:bat[:any_1], X_2:int, X_3:int, X_4:int, X_5:bat[:lng]):bat[:oid] +pattern batsql.window_bound(X_0:bat[:bit], X_1:bat[:any_1], X_2:int, X_3:int, X_4:int, X_5:bat?[:dbl]):bat[:oid] SQLwindow_bound; computes window ranges for each row batsql window_bound -pattern batsql.window_bound(X_0:bat[:bit], X_1:bat[:any_1], X_2:int, X_3:int, X_4:int, X_5:bat[:sht]):bat[:oid] -SQLwindow_bound; -computes window ranges for each row -batsql -window_bound -pattern batsql.window_bound(X_0:bat[:bit], X_1:bat[:any_1], X_2:int, X_3:int, X_4:int, X_5:bte):bat[:oid] -SQLwindow_bound; -computes window ranges for each row -batsql -window_bound -pattern batsql.window_bound(X_0:bat[:bit], X_1:bat[:any_1], X_2:int, X_3:int, X_4:int,
MonetDB: check - merge with default
Changeset: 04574dd85264 for MonetDB URL: https://dev.monetdb.org/hg/MonetDB/rev/04574dd85264 Modified Files: sql/backends/monet5/rel_bin.c sql/include/sql_catalog.h sql/server/rel_schema.c sql/server/sql_mvc.c sql/server/sql_mvc.h sql/server/sql_parser.y sql/storage/sql_storage.h sql/storage/store.c Branch: check Log Message: merge with default diffs (truncated from 175674 to 300 lines): diff --git a/.hgtags b/.hgtags --- a/.hgtags +++ b/.hgtags @@ -822,3 +822,5 @@ 1230526af30f40eeea30fb87c47c3e414920561f 1230526af30f40eeea30fb87c47c3e414920561f Dec2023_release 95d8feaa1167b5ba87bd99253c3f4e62ebf528a1 Dec2023_3 dcc8c702e685a4faf21ccf663028d1bc3d1165d1 Dec2023_5 +dcc8c702e685a4faf21ccf663028d1bc3d1165d1 Dec2023_SP1_release +d656785f49ee62c19705722aa6b7c171904c64d5 Dec2023_7 diff --git a/MonetDB.spec b/MonetDB.spec --- a/MonetDB.spec +++ b/MonetDB.spec @@ -91,7 +91,7 @@ Group: Applications/Databases License: MPL-2.0 URL: https://www.monetdb.org/ BugURL: https://github.com/MonetDB/MonetDB/issues -Source: https://www.monetdb.org/downloads/sources/Dec2023-SP1/%{name}-%{version}.tar.bz2 +Source: https://www.monetdb.org/downloads/sources/Dec2023-SP2/%{name}-%{version}.tar.bz2 # The Fedora packaging document says we need systemd-rpm-macros for # the _unitdir and _tmpfilesdir macros to exist; however on RHEL 7 @@ -679,7 +679,6 @@ This package contains files needed to de %files SQL-server5-devel %defattr(-,root,root) -%{_includedir}/monetdb/exception_buffer.h %{_includedir}/monetdb/opt_backend.h %{_includedir}/monetdb/rel_*.h %{_includedir}/monetdb/sql*.h @@ -808,9 +807,7 @@ do /usr/sbin/semodule -s ${selinuxvariant} -i \ %{_datadir}/selinux/${selinuxvariant}/monetdb.pp &> /dev/null || : done -# use /var/run/monetdb since that's what it says in the monetdb.fc file -# it says that because /run/monetdb for some reason doesn't work -/sbin/restorecon -R %{_localstatedir}/monetdb5 %{_localstatedir}/log/monetdb /var/run/monetdb %{_bindir}/monetdbd %{_bindir}/mserver5 %{_unitdir}/monetdbd.service &> /dev/null || : +/sbin/restorecon -R %{_localstatedir}/monetdb5 %{_localstatedir}/log/monetdb %{_rundir}/monetdb %{_bindir}/monetdbd %{_bindir}/mserver5 %{_unitdir}/monetdbd.service &> /dev/null || : /usr/bin/systemctl try-restart monetdbd.service %postun selinux @@ -839,6 +836,13 @@ fi %setup -q %build +# from Fedora 40, selinux uses /run where before it used /var/run +# the code is now for Fedora 40 but needs a patch for older versions +%if (0%{?fedora} < 40) +sed -i 's;@CMAKE_INSTALL_FULL_RUNSTATEDIR@/monetdb;@CMAKE_INSTALL_FULL_LOCALSTATEDIR@/run/monetdb;' misc/selinux/monetdb.fc.in +sed -i 's/1\.2/1.1/' misc/selinux/monetdb.te +%endif + %cmake3 \ -DCMAKE_INSTALL_RUNSTATEDIR=/run \ -DRELEASE_VERSION=ON \ @@ -917,6 +921,31 @@ fi %endif %changelog +* Tue Apr 09 2024 Sjoerd Mullender - 11.49.7-20240409 +- Rebuilt. +- GH#7469: Crash when using `CONTAINS` +- GH#7479: MonetDB server crashes in `exp_ref` +- GH#7490: commonTerms optimizer no longer works +- GH#7495: Crash when simultaneously querying and updating a string column. + +* Thu Mar 28 2024 Sjoerd Mullender - 11.49.7-20240409 +- gdk: Threads have their own list of free bats. The list was not returned + to the system when a thread exited, meaning that the free bats that + were in the list would not be reused by any thread. This has been + fixed. + +* Tue Mar 19 2024 Sjoerd Mullender - 11.49.7-20240409 +- monetdb5: Fixed interaction between mserver5 and remote mserver5 when only one + of the two has 128 bit integer support. + +* Tue Mar 19 2024 Sjoerd Mullender - 11.49.7-20240409 +- sql: Fixed issue where equal column aliases were created. When those + aliases were parsed on the remote side it could give crashes. + +* Mon Mar 18 2024 Sjoerd Mullender - 11.49.7-20240409 +- gdk: Fixed a couple of deadlock situations, one actually observed, one + never observed. + * Tue Mar 12 2024 Sjoerd Mullender - 11.49.5-20240312 - Rebuilt. - GH#7390: Some MonetDB Server crashes found diff --git a/NT/mksqlwxs.py b/NT/mksqlwxs.py --- a/NT/mksqlwxs.py +++ b/NT/mksqlwxs.py @@ -187,7 +187,7 @@ def main(): print(r'') print(r' ') id = comp(extend, id, 16, - sorted([r'include\monetdb\{}'.format(x) for x in filter(lambda x: (x.startswith('gdk') or x.startswith('monet') or x.startswith('mal') or x.startswith('sql') or x.startswith('rel') or x.startswith('store') or x.startswith('exception') or x.startswith('opt_backend')) and x.endswith('.h'), os.listdir(os.path.join(sys.argv[3], 'include', 'monetdb')))] + + sorted([r'include\monetdb\{}'.format(x) for x in filter(lambda x: (x.startswith('gdk') or x.startswith('monet') or x.startswith('mal') or x.startswith('sql') or x.startswith('rel') or x.startswith('store') or x.startswith('opt_backend')) and x.endswith('.h'),