MonetDB: unlock - Merge with default branch.

2021-01-07 Thread Sjoerd Mullender
Changeset: 043549fbedc4 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=043549fbedc4
Modified Files:
clients/Tests/exports.stable.out
gdk/CMakeLists.txt
gdk/gdk.h
gdk/gdk_aggr.c
gdk/gdk_align.c
gdk/gdk_atoms.c
gdk/gdk_atoms.h
gdk/gdk_bat.c
gdk/gdk_batop.c
gdk/gdk_bbp.c
gdk/gdk_bbp.h
gdk/gdk_calc.c
gdk/gdk_calc_compare.h
gdk/gdk_cand.c
gdk/gdk_cand.h
gdk/gdk_delta.c
gdk/gdk_delta.h
gdk/gdk_firstn.c
gdk/gdk_group.c
gdk/gdk_hash.c
gdk/gdk_heap.c
gdk/gdk_imprints.c
gdk/gdk_interprocess.c
gdk/gdk_join.c
gdk/gdk_logger.c
gdk/gdk_logger.h
gdk/gdk_logger_internals.h
gdk/gdk_logger_old.c
gdk/gdk_orderidx.c
gdk/gdk_private.h
gdk/gdk_project.c
gdk/gdk_sample.c
gdk/gdk_select.c
gdk/gdk_storage.c
gdk/gdk_string.c
gdk/gdk_system.h
gdk/gdk_tm.c
gdk/gdk_unique.c
gdk/gdk_value.c
geom/monetdb5/geom.c
geom/monetdb5/geom.h
geom/monetdb5/geom_upgrade.c
monetdb5/extras/mal_optimizer_template/Tests/opt_sql_append.stable.out
monetdb5/mal/mal.h
monetdb5/mal/mal_atom.c
monetdb5/mal/mal_authorize.c
monetdb5/mal/mal_dataflow.c
monetdb5/mal/mal_debugger.c
monetdb5/mal/mal_interpreter.c
monetdb5/mal/mal_interpreter.h
monetdb5/mal/mal_parser.c
monetdb5/mal/mal_prelude.c
monetdb5/mal/mal_profiler.c
monetdb5/mal/mal_resolve.c
monetdb5/mal/mal_runtime.c
monetdb5/mal/mal_type.c
monetdb5/mal/mal_type.h
monetdb5/mal/mel.h
monetdb5/modules/atoms/batxml.c
monetdb5/modules/atoms/batxml.mal
monetdb5/modules/atoms/blob.c
monetdb5/modules/atoms/inet.c
monetdb5/modules/atoms/json.c
monetdb5/modules/atoms/json.mal
monetdb5/modules/atoms/str.c
monetdb5/modules/kernel/00_aggr_hge.mal
monetdb5/modules/kernel/aggr.c
monetdb5/modules/kernel/aggr.mal
monetdb5/modules/kernel/algebra.c
monetdb5/modules/kernel/algebra.mal
monetdb5/modules/kernel/bat5.c
monetdb5/modules/kernel/bat5.mal
monetdb5/modules/kernel/batcolor.c
monetdb5/modules/kernel/batmmath.c
monetdb5/modules/kernel/batmmath.mal
monetdb5/modules/kernel/batstr.c
monetdb5/modules/kernel/group.c
monetdb5/modules/kernel/group.mal
monetdb5/modules/kernel/status.c
monetdb5/modules/mal/00_batcalc_hge.mal
monetdb5/modules/mal/00_calc_hge.mal
monetdb5/modules/mal/01_batcalc.mal
monetdb5/modules/mal/01_calc.mal
monetdb5/modules/mal/CMakeLists.txt
monetdb5/modules/mal/batMask.c
monetdb5/modules/mal/batMask.mal
monetdb5/modules/mal/batcalc.c
monetdb5/modules/mal/batmtime.mal
monetdb5/modules/mal/calc.c
monetdb5/modules/mal/manifold.c
monetdb5/modules/mal/mat.c
monetdb5/modules/mal/pcre.c
monetdb5/modules/mal/pcre.mal
monetdb5/modules/mal/projectionpath.c
monetdb5/modules/mal/querylog.c
monetdb5/modules/mal/remote.c
monetdb5/modules/mal/tablet.c
monetdb5/modules/mal/tokenizer.c
monetdb5/modules/mal/transaction.c
monetdb5/modules/mal/txtsim.c
monetdb5/optimizer/CMakeLists.txt
monetdb5/optimizer/opt_emptybind.c
monetdb5/optimizer/opt_mask.c
monetdb5/optimizer/opt_mask.h
monetdb5/optimizer/opt_mergetable.c
monetdb5/optimizer/opt_pipes.c
monetdb5/optimizer/opt_prelude.c
monetdb5/optimizer/opt_prelude.h
monetdb5/optimizer/opt_pushselect.c
monetdb5/optimizer/opt_remap.c
monetdb5/optimizer/opt_support.c
monetdb5/optimizer/opt_volcano.c
monetdb5/optimizer/opt_wlc.c
monetdb5/optimizer/opt_wrapper.c
monetdb5/optimizer/optimizer.c
sql/backends/monet5/CMakeLists.txt
sql/backends/monet5/UDF/capi/capi.c
sql/backends/monet5/UDF/pyapi3/conversion3.c
sql/backends/monet5/UDF/pyapi3/convert_loops.h
sql/backends/monet5/UDF/pyapi3/pyapi3.c
sql/backends/monet5/UDF/udf/udf.c
sql/backends/monet5/generator/generator.c
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql.h
sql/backends/monet5/sql.mal
sql/backends/monet5/sql_cat.c
sql/backends/monet5/sql_gencode.c
sql/backends/monet5/sql_gencode.h
sql/backends/monet5/sql_optimizer.c
sql/backends/monet5/sql_result.c
sql/backends/monet5/sql_result.h
sql/backends/monet5/sql_scenario.c
sql/backends/monet5/sql_statement.c
sql/backends/monet5/sql_statement.h
sql/backends/monet5

MonetDB: unlock - Merge with default branch.

2020-12-21 Thread Sjoerd Mullender
Changeset: 0ffbc159626f for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=0ffbc159626f
Modified Files:
gdk/gdk_join.c
gdk/gdk_private.h
sql/common/sql_types.c
sql/server/rel_updates.c
sql/test/mapi/Tests/sql_int128.stable.out.int128
sql/test/mapi/Tests/sql_int128.test
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 1684 to 300 lines):

diff --git a/MonetDB.spec b/MonetDB.spec
--- a/MonetDB.spec
+++ b/MonetDB.spec
@@ -2698,7 +2698,7 @@ sed -i 's|/var/run|/run|' \
   are equal to 1.1.  (The old code returned 33554432 instead of 1.1e8.)
 
 * Sun Nov  5 2017 Sjoerd Mullender  - 11.27.9-20171105
-- BZ#6460 - selinux doen't allow mmap
+- BZ#6460: selinux doen't allow mmap
 
 * Mon Oct 23 2017 Sjoerd Mullender  - 11.27.9-20171023
 - Rebuilt.
diff --git a/debian/changelog b/debian/changelog
--- a/debian/changelog
+++ b/debian/changelog
@@ -2469,6 +2469,12 @@ monetdb (11.27.11) unstable; urgency=low
 
 monetdb (11.27.9) unstable; urgency=low
 
+  * BZ#6460: selinux doen't allow mmap
+
+ -- Sjoerd Mullender   Sun, 5 Nov 2017 09:56:39 +0100
+
+monetdb (11.27.9) unstable; urgency=low
+
   * Rebuilt.
   * BZ#6207: identifier ambiguous when grouping and selecting the same
 column twice
diff --git a/gdk/gdk_join.c b/gdk/gdk_join.c
--- a/gdk/gdk_join.c
+++ b/gdk/gdk_join.c
@@ -2502,7 +2502,8 @@ hashjoin(BAT **r1p, BAT **r2p, BAT *l, B
 struct canditer *restrict lci, struct canditer *restrict rci,
 bool nil_matches, bool nil_on_miss, bool semi, bool only_misses,
 bool not_in, bool max_one, bool min_one,
-BUN estimate, lng t0, bool swapped, bool hash, bool phash,
+BUN estimate, lng t0, bool swapped,
+bool hash, bool phash, bool hash_cand,
 const char *reason)
 {
oid lo, ro;
@@ -2521,7 +2522,6 @@ hashjoin(BAT **r1p, BAT **r2p, BAT *l, B
const char *v = (const char *) &lval;
bool lskipped = false;  /* whether we skipped values in l */
Hash *restrict hsh = NULL;
-   bool hash_cand = false;
 
assert(!BATtvoid(r));
assert(ATOMtype(l->ttype) == ATOMtype(r->ttype));
@@ -2558,7 +2558,24 @@ hashjoin(BAT **r1p, BAT **r2p, BAT *l, B
 
rl = rci->seq - r->hseqbase;
rh = canditer_last(rci) + 1 - r->hseqbase;
-   if (phash) {
+   if (hash_cand) {
+   /* we need to create a hash on r specific for the
+* candidate list */
+   char ext[32];
+   assert(rci->s);
+   MT_thread_setalgorithm(swapped ? "hashjoin using candidate hash 
(swapped)" : "hashjoin using candidate hash");
+   TRC_DEBUG(ALGO, ALGOBATFMT ": creating "
+ "hash for candidate list " ALGOBATFMT "%s%s\n",
+ ALGOBATPAR(r), ALGOBATPAR(rci->s),
+ r->thash ? " ignoring existing hash" : "",
+ swapped ? " (swapped)" : "");
+   if (snprintf(ext, sizeof(ext), "thshjn%x",
+(unsigned) rci->s->batCacheid) >= (int) 
sizeof(ext))
+   goto bailout;
+   if ((hsh = BAThash_impl(r, rci, ext)) == NULL) {
+   goto bailout;
+   }
+   } else if (phash) {
/* there is a hash on the parent which we should use */
MT_thread_setalgorithm(swapped ? "hashjoin using parent hash 
(swapped)" : "hashjoin using parent hash");
BAT *b = BBPdescriptor(VIEWtparent(r));
@@ -2580,24 +2597,6 @@ hashjoin(BAT **r1p, BAT **r2p, BAT *l, B
  "existing hash%s\n",
  ALGOBATPAR(r),
  swapped ? " (swapped)" : "");
-   } else if (rci->tpe != cand_dense || rci->ncand != BATcount(r)) {
-   /* we need to create a hash on r specific for the
-* candidate list */
-   char ext[32];
-   assert(rci->s);
-   MT_thread_setalgorithm(swapped ? "hashjoin using candidate hash 
(swapped)" : "hashjoin using candidate hash");
-   TRC_DEBUG(ALGO, ALGOBATFMT ": creating "
- "hash for candidate list " ALGOBATFMT "%s%s\n",
- ALGOBATPAR(r), ALGOBATPAR(rci->s),
- r->thash ? " ignoring existing hash" : "",
- swapped ? " (swapped)" : "");
-   if (snprintf(ext, sizeof(ext), "thshjn%x",
-(unsigned) rci->s->batCacheid) >= (int) 
sizeof(ext))
-   goto bailout;
-   if ((hsh = BAThash_impl(r, rci, ext)) == NULL) {
-   goto bailout;
-   }
-   hash_cand = true;
} else {
/* we need to create a hash on r */
MT_thread_setalgorithm(swapped ? "hashjoin using new hash 
(swapped)" : "hashjoin using new hash");
@@ -3078,

MonetDB: unlock - Merge with default branch.

2020-11-09 Thread Sjoerd Mullender
Changeset: 9a172540 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=9a172540
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
gdk/gdk_string.c
monetdb5/mal/mal_profiler.c
monetdb5/mal/mal_runtime.c
sql/backends/monet5/UDF/pyapi3/pyapi3.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql_upgrades.c
sql/common/sql_types.c
sql/include/sql_catalog.h
sql/include/sql_relation.h
sql/server/rel_optimizer.c
sql/server/rel_updates.c
sql/test/analytics/Tests/analytics14.stable.out
sql/test/emptydb/Tests/check.stable.out
sql/test/emptydb/Tests/check.stable.out.32bit
sql/test/emptydb/Tests/check.stable.out.int128
sql/test/pg_regress/Tests/alter_table.stable.err
sql/test/subquery/Tests/correlated.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
tools/monetdbe/monetdbe.c
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 147457 to 300 lines):

diff --git a/clients/Tests/MAL-signatures.stable.out 
b/clients/Tests/MAL-signatures.stable.out
--- a/clients/Tests/MAL-signatures.stable.out
+++ b/clients/Tests/MAL-signatures.stable.out
@@ -1376,42 +1376,10 @@ stdout of test 'MAL-signatures` in direc
 [ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:flt], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:int] ", "CMDbatMULsignal;", ""  ]
 [ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:flt], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:lng] ", "CMDbatMULsignal;", ""  ]
 [ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:flt], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:sht] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:int], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:bte] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:int], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:bte] ", "CMDbatMULsignal;", ""  ]
 [ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:int], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:int] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:int], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:int] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:int], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:int] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:int], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:lng] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:int], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:lng] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:int], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:sht] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:int], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:sht] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:lng], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:bte] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:lng], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:bte] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:lng], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:int] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:lng], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:int] ", "CMDbatMULsignal;", ""  ]
 [ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:lng], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:lng] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:lng], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:lng] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:lng], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:lng] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:lng], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:sht] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:lng], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:sht] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:sht], 
X_3:bat[:oid], X_4:bat[:oid]):bat[:bte] ", "CMDbatMULsignal;", ""  ]
-[ "batcalc",   "*","pattern batcalc.*(X_1:bat[:bte], X_2:bat[:sht], 
X_3:bat[:oid], 

MonetDB: unlock - Merge with default branch.

2020-11-03 Thread Sjoerd Mullender
Changeset: b80bf6abd0c3 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=b80bf6abd0c3
Modified Files:
gdk/gdk_system.h
Branch: unlock
Log Message:

Merge with default branch.


diffs (23 lines):

diff --git a/common/utils/matomic.h b/common/utils/matomic.h
--- a/common/utils/matomic.h
+++ b/common/utils/matomic.h
@@ -220,6 +220,7 @@ typedef PVOID volatile ATOMIC_PTR_TYPE;
 #define ATOMIC_PTR_GET(var)(*(var))
 #define ATOMIC_PTR_SET(var, val)   _InterlockedExchangePointer(var, 
(PVOID) (val))
 #define ATOMIC_PTR_XCG(var, val)   _InterlockedExchangePointer(var, 
(PVOID) (val))
+#pragma intrinsic(_InterlockedCompareExchangePointer)
 static inline bool
 ATOMIC_PTR_CAS(ATOMIC_PTR_TYPE *var, void **exp, void *des)
 {
diff --git a/gdk/gdk_system.h b/gdk/gdk_system.h
--- a/gdk/gdk_system.h
+++ b/gdk/gdk_system.h
@@ -320,8 +320,6 @@ static void wininit_##n(void)   
\
 __declspec(allocate(".CRT$XCU")) void (*wininit_##n##_)(void) = wininit_##n; \
 __pragma(comment(linker, "/include:" _LOCK_PREF_ "wininit_" #n "_"))
 
-#pragma intrinsic(_InterlockedCompareExchangePointer)
-
 #define MT_lock_init(l, n) \
do {\
InitializeCriticalSection(&(l)->lock);  \
___
checkin-list mailing list
checkin-list@monetdb.org
https://www.monetdb.org/mailman/listinfo/checkin-list


MonetDB: unlock - Merge with default branch.

2020-11-03 Thread Sjoerd Mullender
Changeset: 9951c4e33293 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=9951c4e33293
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
gdk/gdk_bbp.c
gdk/gdk_sample.c
gdk/gdk_system.h
monetdb5/mal/mal_dataflow.c
monetdb5/modules/mal/querylog.c
monetdb5/modules/mal/remote.c
monetdb5/modules/mal/tablet.c
monetdb5/optimizer/opt_pipes.c
sql/backends/monet5/UDF/capi/capi.c
sql/backends/monet5/UDF/pyapi3/pyapi3.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql_scenario.c
sql/backends/monet5/wlr.c
sql/server/sql_mvc.h
sql/storage/bat/bat_storage.c
sql/storage/sql_storage.h
sql/storage/store.c
tools/monetdbe/monetdbe.c
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 1939 to 300 lines):

diff --git a/clients/Tests/MAL-signatures.stable.out 
b/clients/Tests/MAL-signatures.stable.out
--- a/clients/Tests/MAL-signatures.stable.out
+++ b/clients/Tests/MAL-signatures.stable.out
@@ -9701,6 +9701,7 @@ stdout of test 'MAL-signatures` in direc
 [ "inspect",   "getDefinition","pattern inspect.getDefinition(X_1:str, 
X_2:str):bat[:str] ",   "INSPECTgetDefinition;",""  ]
 [ "inspect",   "getEnvironment",   "command inspect.getEnvironment() 
(X_0:bat[:str], X_1:bat[:str]) ", "INSPECTgetEnvironment;",   ""  ]
 [ "inspect",   "getEnvironment",   "command 
inspect.getEnvironment(X_1:str):str ", "INSPECTgetEnvironmentKey;",""  ]
+[ "inspect",   "getExistence", "pattern inspect.getExistence(X_1:str, 
X_2:str):bit ",  "INSPECTgetExistence;", ""  ]
 [ "inspect",   "getFunction",  "pattern inspect.getFunction():bat[:str] ", 
"INSPECTgetAllFunctions;",  ""  ]
 [ "inspect",   "getKind",  "pattern inspect.getKind():bat[:str] ", 
"INSPECTgetkind;",  ""  ]
 [ "inspect",   "getModule","pattern inspect.getModule():bat[:str] ",   
"INSPECTgetAllModules;",""  ]
@@ -10185,11 +10186,12 @@ stdout of test 'MAL-signatures` in direc
 [ "remote","exec", "pattern remote.exec(X_1:str, X_2:str, X_3:str, 
X_4:ptr, X_5:str...):void ","RMTexec;", ""  ]
 [ "remote","exec", "pattern remote.exec(X_1:str, X_2:str, X_3:str, 
X_4:str...):str ",  "RMTexec;", ""  ]
 [ "remote","exec", "pattern remote.exec(X_1:str, X_2:str, X_3:str, 
X_4:str...):str... ",   "RMTexec;", ""  ]
+[ "remote","exec", "pattern remote.exec(X_1:str, X_2:str, X_3:str, 
X_4:str...):void ", "RMTexec;", ""  ]
 [ "remote","get",  "pattern remote.get(X_1:str, X_2:str):any ",
"RMTget;",  ""  ]
 [ "remote","isalive",  "command remote.isalive(X_1:str):int ", 
"RMTisalive;",  ""  ]
 [ "remote","prelude",  "command remote.prelude():void ",   
"RMTprelude;",  ""  ]
 [ "remote","put",  "pattern remote.put(X_1:str, X_2:any):str ",
"RMTput;",  ""  ]
-[ "remote","register", "pattern remote.register(X_1:str, X_2:str, 
X_3:str):void ", "RMTregister;", ""  ]
+[ "remote","register", "pattern remote.register(X_1:str, X_2:str, 
X_3:str):str ",  "RMTregister;", ""  ]
 [ "remote","register_supervisor",  "command 
remote.register_supervisor(X_1:str, X_2:str):int ",
"RMTregisterSupervisor;",   ""  ]
 [ "remote","resolve",  "command remote.resolve(X_1:str):bat[:str] ",   
"RMTresolve;",  ""  ]
 [ "sample","subuniform",   "pattern sample.subuniform(X_1:bat[:any], 
X_2:dbl):bat[:oid] ", "SAMPLEuniform;",   ""  ]
diff --git a/clients/Tests/MAL-signatures.stable.out.int128 
b/clients/Tests/MAL-signatures.stable.out.int128
--- a/clients/Tests/MAL-signatures.stable.out.int128
+++ b/clients/Tests/MAL-signatures.stable.out.int128
@@ -12115,6 +12115,7 @@ stdout of test 'MAL-signatures` in direc
 [ "inspect",   "getDefinition","pattern inspect.getDefinition(X_1:str, 
X_2:str):bat[:str] ",   "INSPECTgetDefinition;",""  ]
 [ "inspect",   "getEnvironment",   "command inspect.getEnvironment() 
(X_0:bat[:str], X_1:bat[:str]) ", "INSPECTgetEnvironment;",   ""  ]
 [ "inspect",   "getEnvironment",   "command 
inspect.getEnvironment(X_1:str):str ", "INSPECTgetEnvironmentKey;",""  ]
+[ "inspect",   "getExistence", "pattern inspect.getExistence(X_1:str, 
X_2:str):bit ",  "INSPECTgetExistence;", ""  ]
 [ "inspect",   "getFunction",  "pattern inspect.getFunction():bat[:str] ", 
"INSPECTgetAllFunctions;",  ""  ]
 [ "inspect",   "getKind",  "pattern inspect.getKind():bat[:str] ", 
"INSPECTgetkind;",  ""  ]
 [ "inspect",   "getModule","pattern inspect.getModule():bat[:str] ",   
"INSPECTgetAllModules;",""  ]
@@ -12605,11 +12606,12 @@ stdout of test 'MAL-signatures` in direc
 [ "remote","exec", "patte

MonetDB: unlock - Merge with default branch.

2020-11-02 Thread Sjoerd Mullender
Changeset: d4e591cbc5d0 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=d4e591cbc5d0
Modified Files:
gdk/gdk_aggr.c
gdk/gdk_group.c
gdk/gdk_join.c
gdk/gdk_select.c
gdk/gdk_unique.c
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql_scenario.c
sql/backends/monet5/sql_upgrades.c
sql/include/sql_catalog.h
sql/server/rel_updates.c
sql/server/sql_parser.y
sql/server/sql_scan.c
sql/storage/store.c
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 1586 to 300 lines):

diff --git a/clients/mapiclient/dump.c b/clients/mapiclient/dump.c
--- a/clients/mapiclient/dump.c
+++ b/clients/mapiclient/dump.c
@@ -1315,7 +1315,7 @@ describe_table(Mapi mid, const char *sch
/* the table is a real table */
mnstr_printf(toConsole, "CREATE %sTABLE ",
type == 3 ? "MERGE " :
-   type == 4 ? "STREAM " :
+   /*type == 4 ? "STREAM " : */
type == 5 ? "REMOTE " :
type == 6 ? "REPLICA " :
"");
diff --git a/clients/mapiclient/mhelp.c b/clients/mapiclient/mhelp.c
--- a/clients/mapiclient/mhelp.c
+++ b/clients/mapiclient/mhelp.c
@@ -208,11 +208,6 @@ SQLhelp sqlhelp1[] = {
 "[MINVALUE intval | NO MINVALUE] [MAXVALUE intval | NO MAXVALUE] 
[CACHE intval] [[NO] CYCLE]",
 "seq_int_datatype,intval",
 "See also 
https://www.monetdb.org/Documentation/Manuals/SQLreference/SerialTypes"},
-   {"CREATE STREAM TABLE",
-"Temporary table, locked during updates/ continues query processing",
-"CREATE STREAM TABLE [ IF NOT EXISTS ] qname table_source\n",
-"table_source",
-NULL},
{"CREATE TABLE",
 "Create a new table",
 "CREATE TABLE [ IF NOT EXISTS ] qname table_source [STORAGE ident 
string]\n"
diff --git a/gdk/gdk_aggr.c b/gdk/gdk_aggr.c
--- a/gdk/gdk_aggr.c
+++ b/gdk/gdk_aggr.c
@@ -3575,6 +3575,7 @@ BATmin_skipnil(BAT *b, void *aggr, bit s
const oid *ords = (const oid *) (pb ? 
pb->torderidx->base : b->torderidx->base) + ORDERIDXOFF;
BUN r;
if (!b->tnonil) {
+   MT_thread_setalgorithm(pb ? "binsearch on 
parent oidx" : "binsearch on oids");
r = binsearch(ords, 0, b->ttype, Tloc(b, 0),
  b->tvheap ? b->tvheap->base : 
NULL,
  b->twidth, 0, BATcount(b),
@@ -3590,6 +3591,7 @@ BATmin_skipnil(BAT *b, void *aggr, bit s
/* no non-nil values */
pos = oid_nil;
} else {
+   MT_thread_setalgorithm(pb ? "using parent oidx" 
: "using oids");
pos = ords[r];
}
} else if ((VIEWtparent(b) == 0 ||
@@ -3599,6 +3601,8 @@ BATmin_skipnil(BAT *b, void *aggr, bit s
Imprints *imprints = VIEWtparent(b) ? 
BBPdescriptor(VIEWtparent(b))->timprints : b->timprints;
int i;
 
+
+   MT_thread_setalgorithm(VIEWtparent(b) ? "using parent 
imprints" : "using imprints");
pos = oid_nil;
/* find first non-empty bin */
for (i = 0; i < imprints->bits; i++) {
@@ -3681,6 +3685,7 @@ BATmax_skipnil(BAT *b, void *aggr, bit s
 BATcheckorderidx(pb))) {
const oid *ords = (const oid *) (pb ? 
pb->torderidx->base : b->torderidx->base) + ORDERIDXOFF;
 
+   MT_thread_setalgorithm(pb ? "using parent oidx" : 
"using oids");
pos = ords[BATcount(b) - 1];
/* nils are first, ie !skipnil, check for nils */
if (!skipnil) {
@@ -3699,6 +3704,7 @@ BATmax_skipnil(BAT *b, void *aggr, bit s
Imprints *imprints = VIEWtparent(b) ? 
BBPdescriptor(VIEWtparent(b))->timprints : b->timprints;
int i;
 
+   MT_thread_setalgorithm(VIEWtparent(b) ? "using parent 
imprints" : "using imprints");
pos = oid_nil;
/* find last non-empty bin */
for (i = imprints->bits - 1; i >= 0; i--) {
@@ -3981,6 +3987,7 @@ doBATgroupquantile(BAT *b, BAT *g, BAT *
 BATcount(pb) == BATcount(b) &&
 pb->hseqbase == b->hseqbase &&
 BATcheckorderidx(pb))) {
+   MT_thread_setalgorithm(pb ? "using parent oidx" : 
"using oids");
ords = (const oid *) (pb ? pb->torderidx->base : 
b->torderidx->

MonetDB: unlock - Merge with default branch.

2020-10-28 Thread Sjoerd Mullender
Changeset: dd7c6946f4db for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=dd7c6946f4db
Modified Files:
monetdb5/modules/atoms/json.c
Branch: unlock
Log Message:

Merge with default branch.


diffs (50 lines):

diff --git a/monetdb5/modules/atoms/json.c b/monetdb5/modules/atoms/json.c
--- a/monetdb5/modules/atoms/json.c
+++ b/monetdb5/modules/atoms/json.c
@@ -2361,18 +2361,18 @@ JSONjsonaggr(BAT **bnp, BAT *b, BAT *g, 
freeg = 1;
if (t2->ttype == TYPE_void) {
map = NULL;
-   mapoff = t2->tseqbase;
} else {
map = (const oid *) Tloc(t2, 0);
+   mapoff = t2->tseqbase;
}
if (g && BATtdense(g)) {
for (p = 0, q = BATcount(g); p < q; p++) {
switch (b->ttype) {
case TYPE_str:
-   v = (const char *) BUNtvar(bi, (map ? 
(BUN) map[p] : p + mapoff));
+   v = (const char *) BUNtvar(bi, (map ? 
(BUN) map[p] - mapoff : p));
break;
case TYPE_dbl:
-   val = (const double *) BUNtloc(bi, (map 
? (BUN) map[p] : p + mapoff));
+   val = (const double *) BUNtloc(bi, (map 
? (BUN) map[p] - mapoff : p));
if (!is_dbl_nil(*val)) {
snprintf(temp, sizeof(temp), 
"%f", *val);
v = (const char *) temp;
diff --git a/sql/backends/monet5/sql_subquery.c 
b/sql/backends/monet5/sql_subquery.c
--- a/sql/backends/monet5/sql_subquery.c
+++ b/sql/backends/monet5/sql_subquery.c
@@ -205,12 +205,15 @@ SQLall(ptr ret, const bat *bid)
}
}
s = ATOMlen(ATOMtype(b->ttype), p);
-   *(ptr *) ret = GDKmalloc(s);
-   if (*(ptr *) ret == NULL) {
-   BBPunfix(b->batCacheid);
-   throw(SQL, "sql.all", SQLSTATE(HY013) 
MAL_MALLOC_FAIL);
-   }
-   memcpy(*(ptr *)ret, p, s);
+   if (ATOMextern(b->ttype)) {
+   *(ptr *) ret = GDKmalloc(s);
+   if (*(ptr *) ret == NULL) {
+   BBPunfix(b->batCacheid);
+   throw(SQL, "sql.all", SQLSTATE(HY013) 
MAL_MALLOC_FAIL);
+   }
+   memcpy(*(ptr *)ret, p, s);
+   } else
+   memcpy(ret, p, s);
}
}
}
___
checkin-list mailing list
checkin-list@monetdb.org
https://www.monetdb.org/mailman/listinfo/checkin-list


MonetDB: unlock - Merge with default branch.

2020-10-28 Thread Sjoerd Mullender
Changeset: 98af1da2ca66 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=98af1da2ca66
Removed Files:

sql/test/BugTracker-2009/Tests/segfault_when_quitting_debugger.SF-2538837.stable.out
Modified Files:
monetdb5/mal/mal_debugger.c
sql/test/BugTracker-2009/Tests/All
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 1225 to 300 lines):

diff --git a/NT/mkodbcwxs.py b/NT/mkodbcwxs.py
--- a/NT/mkodbcwxs.py
+++ b/NT/mkodbcwxs.py
@@ -77,8 +77,8 @@ def main():
 print(r'')
 id = comp(features, id, 14,
   [r'bin\mapi.dll', # r'lib\mapi.pdb',
-   r'bin\MonetODBC.dll', # r'lib\MonetODBC.pdb',
-   r'bin\MonetODBCs.dll', # r'lib\MonetODBCs.pdb',
+   r'lib\MonetODBC.dll', # r'lib\MonetODBC.pdb',
+   r'lib\MonetODBCs.dll', # r'lib\MonetODBCs.pdb',
r'bin\stream.dll', # r'lib\stream.pdb',
vcpkg.format(r'bin\libiconv.dll'),
vcpkg.format(r'bin\bz2.dll'),
diff --git a/clients/odbc/driver/CMakeLists.txt 
b/clients/odbc/driver/CMakeLists.txt
--- a/clients/odbc/driver/CMakeLists.txt
+++ b/clients/odbc/driver/CMakeLists.txt
@@ -7,7 +7,7 @@
 #]]
 
 add_library(MonetODBC
-  SHARED)
+  MODULE)
 
 target_sources(MonetODBC
   PRIVATE
@@ -114,7 +114,7 @@ target_include_directories(MonetODBC
   $)
 
 target_compile_definitions(MonetODBC
-  PRIVATE 
+  PRIVATE
   LIBMONETODBCS)
 
 target_link_libraries(MonetODBC
diff --git a/clients/odbc/setup/CMakeLists.txt 
b/clients/odbc/setup/CMakeLists.txt
--- a/clients/odbc/setup/CMakeLists.txt
+++ b/clients/odbc/setup/CMakeLists.txt
@@ -7,11 +7,11 @@
 #]]
 
 add_library(MonetODBCs
-  SHARED)
+  MODULE)
 
 target_sources(MonetODBCs
   PRIVATE
-  drvcfg.c 
+  drvcfg.c
   drvcfg.h)
 
 target_include_directories(MonetODBCs
@@ -21,8 +21,8 @@ target_include_directories(MonetODBCs
   $
   $)
 
-target_compile_definitions(MonetODBCs 
-  PRIVATE 
+target_compile_definitions(MonetODBCs
+  PRIVATE
   LIBMONETODBCS)
 
 target_link_libraries(MonetODBCs
diff --git a/clients/odbc/winsetup/CMakeLists.txt 
b/clients/odbc/winsetup/CMakeLists.txt
--- a/clients/odbc/winsetup/CMakeLists.txt
+++ b/clients/odbc/winsetup/CMakeLists.txt
@@ -7,7 +7,7 @@
 #]]
 
 add_library(MonetODBCs
-  SHARED)
+  MODULE)
 
 target_sources(MonetODBCs
   PRIVATE
@@ -23,8 +23,8 @@ target_include_directories(MonetODBCs
   $
   $)
 
-target_compile_definitions(MonetODBCs 
-  PRIVATE 
+target_compile_definitions(MonetODBCs
+  PRIVATE
   LIBMONETODBCS)
 
 target_link_libraries(MonetODBCs
diff --git a/ctest/cmake/detect-bz2.cmake b/ctest/cmake/detect-bz2.cmake
--- a/ctest/cmake/detect-bz2.cmake
+++ b/ctest/cmake/detect-bz2.cmake
@@ -27,19 +27,7 @@ elseif (${LINUX_DISTRO} STREQUAL "ubuntu
   variablename BZIP2_FOUND)
   endif()
 elseif(${LINUX_DISTRO} STREQUAL "fedora")
-  if(${LINUX_DISTRO_VERSION} STREQUAL "30")
-assert_package_detected(
-  detect TRUE
-  legacyvariable HAVE_LIBBZ2
-  variablename BZIP2_FOUND)
-  endif()
-  if(${LINUX_DISTRO_VERSION} STREQUAL "31")
-assert_package_detected(
-  detect TRUE
-  legacyvariable HAVE_LIBBZ2
-  variablename BZIP2_FOUND)
-  endif()
-  if(${LINUX_DISTRO_VERSION} STREQUAL "32")
+  if(${LINUX_DISTRO_VERSION} VERSION_GREATER_EQUAL "30")
 assert_package_detected(
   detect TRUE
   legacyvariable HAVE_LIBBZ2
diff --git a/ctest/cmake/detect-commoncrypto.cmake 
b/ctest/cmake/detect-commoncrypto.cmake
--- a/ctest/cmake/detect-commoncrypto.cmake
+++ b/ctest/cmake/detect-commoncrypto.cmake
@@ -27,19 +27,7 @@ elseif (${LINUX_DISTRO} STREQUAL "ubuntu
   variablename COMMONCRYPTO_FOUND)
   endif()
 elseif(${LINUX_DISTRO} STREQUAL "fedora")
-  if(${LINUX_DISTRO_VERSION} STREQUAL "30")
-assert_package_detected(
-  detect FALSE
-  legacyvariable HAVE_COMMONCRYPTO
-  variablename COMMONCRYPTO_FOUND)
-  endif()
-  if(${LINUX_DISTRO_VERSION} STREQUAL "31")
-assert_package_detected(
-  detect FALSE
-  legacyvariable HAVE_COMMONCRYPTO
-  variablename COMMONCRYPTO_FOUND)
-  endif()
-  if(${LINUX_DISTRO_VERSION} STREQUAL "32")
+  if(${LINUX_DISTRO_VERSION} VERSION_GREATER_EQUAL "30")
 assert_package_detected(
   detect FALSE
   legacyvariable HAVE_COMMONCRYPTO
diff --git a/ctest/cmake/detect-curl.cmake b/ctest/cmake/detect-curl.cmake
--- a/ctest/cmake/detect-curl.cmake
+++ b/ctest/cmake/detect-curl.cmake
@@ -27,19 +27,7 @@ elseif (${LINUX_DISTRO} STREQUAL "ubuntu
   variablename CURL_FOUND)
   endif()
 elseif(${LINUX_DISTRO} STREQUAL "fedora")
-  if(${LINUX_DISTRO_VERSION} STREQUAL "30")
-assert_package_detected(
-  detect TRUE
-  legacyvariable HAVE_CURL
-  variablename CURL_FOUND)
-  endif()
-  if(${LINUX_DISTRO_VERSION} STREQUAL "31")
-assert_package_detected(
-  detect TRUE
-  legacyvariable HAVE_CURL
-  variablename CURL_FOUND)
-  endif()
-  if(${LINUX_DISTRO_VERSION} STREQUAL "32")
+  if(${L

MonetDB: unlock - Merge with default branch.

2020-10-16 Thread Sjoerd Mullender
Changeset: 7ea83bfa1bbb for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=7ea83bfa1bbb
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
gdk/gdk_calc_compare.h
gdk/gdk_string.c
geom/monetdb5/geom_upgrade.c
monetdb5/modules/atoms/json.c
monetdb5/modules/mal/batcalc.c
monetdb5/modules/mal/calc.c
monetdb5/optimizer/opt_pushselect.c
sql/common/sql_types.c
sql/server/rel_optimizer.c
sql/test/BugTracker-2009/Tests/All

sql/test/BugTracker-2009/Tests/segfault_when_quitting_debugger.SF-2538837.stable.out
sql/test/BugTracker/Tests/jdbc_no_debug.SF-1739356.stable.out
sql/test/emptydb/Tests/check.stable.out
sql/test/emptydb/Tests/check.stable.out.32bit
sql/test/emptydb/Tests/check.stable.out.int128
sql/test/sys-schema/Tests/systemfunctions.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 88465 to 300 lines):

diff --git a/clients/Tests/MAL-signatures.stable.out 
b/clients/Tests/MAL-signatures.stable.out
--- a/clients/Tests/MAL-signatures.stable.out
+++ b/clients/Tests/MAL-signatures.stable.out
@@ -1044,1287 +1044,1279 @@ stdout of test 'MAL-signatures` in direc
 [ "batcalc",   "!=",   "pattern batcalc.!=(X_1:uuid, X_2:bat[:uuid], 
X_3:bat[:cnd]):bat[:bit] ",   "CMDbatNE;",""  ]
 [ "batcalc",   "!=",   "pattern batcalc.!=(X_1:uuid, X_2:bat[:uuid], 
X_3:bat[:cnd], X_4:bit):bat[:bit] ",  "CMDbatNE;",""  ]
 [ "batcalc",   "!=",   "pattern batcalc.!=(X_1:uuid, X_2:bat[:uuid], 
X_3:bit):bat[:bit] ", "CMDbatNE;",""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:bte], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:bte] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:bte], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:int] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:bte], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:lng] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:bte], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:sht] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:int], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:bte] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:int], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:int] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:int], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:lng] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:int], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:sht] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:lng], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:bte] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:lng], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:int] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:lng], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:lng] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:lng], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:sht] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:sht], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:bte] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:sht], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:int] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:sht], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:lng] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bat[:sht], 
X_3:bat[:cnd], X_4:bat[:cnd]):bat[:sht] ", "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bte, 
X_3:bat[:cnd]):bat[:bte] ",  "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bte, 
X_3:bat[:cnd]):bat[:int] ",  "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bte, 
X_3:bat[:cnd]):bat[:lng] ",  "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:bte, 
X_3:bat[:cnd]):bat[:sht] ",  "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:int, 
X_3:bat[:cnd]):bat[:bte] ",  "CMDbatMODsignal;", ""  ]
-[ "batcalc",   "%","pattern batcalc.%(X_1:bat[:bte], X_2:int, 
X_3:bat[

MonetDB: unlock - Merge with default branch.

2020-10-15 Thread Sjoerd Mullender
Changeset: dcc0c57d7318 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=dcc0c57d7318
Modified Files:
ChangeLog
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
gdk/gdk_join.c
gdk/gdk_private.h
gdk/gdk_storage.c
monetdb5/mal/mal_authorize.c
monetdb5/mal/mal_prelude.c
monetdb5/modules/kernel/batmmath.c
monetdb5/modules/kernel/batstr.c
monetdb5/modules/mal/batcalc.c
monetdb5/modules/mal/calc.c
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql.h
sql/backends/monet5/sql_scenario.c
sql/backends/monet5/sql_upgrades.c
sql/common/sql_types.c
sql/server/rel_optimizer.c
sql/server/rel_updates.c
sql/storage/store.c
sql/test/sys-schema/Tests/systemfunctions.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
tools/merovingian/daemon/controlrunner.c
tools/monetdbe/monetdbe.c
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 10318 to 300 lines):

diff --git a/.github/ISSUE_TEMPLATE/bug_report.md 
b/.github/ISSUE_TEMPLATE/bug_report.md
new file mode 100644
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/bug_report.md
@@ -0,0 +1,34 @@
+---
+name: Bug report
+about: Create a report to help us improve the sytem 
+title: ''
+labels: ''
+assignees: ''
+
+---
+
+**Describe the bug**
+A clear and concise description of what the bug is.
+
+**To Reproduce**
+Create a setting with minimal input for an external user to demonstrate him 
the buggy behavior.
+This includes the relevant part of the database  schema description.
+Performance trace of the roque query (using the TRACE command)
+
+**Expected behavior**
+A clear and concise description of what you expected to happen.
+
+**Screenshots**
+If applicable, add screenshots to help explain your problem.
+
+**Software versions**
+ - MonetDB version number [a milestone label]
+ - OS and version: [e.g. Ubuntu 18.04]
+ - Installed from release package or self-installed and compiled
+
+
+**Issue labeling **
+Make liberal use of the labels to characterise the issue topics. e.g. identify 
severity, version, etc..
+
+**Additional context**
+Add any other context about the problem here.
diff --git a/.github/ISSUE_TEMPLATE/feature_request.md 
b/.github/ISSUE_TEMPLATE/feature_request.md
new file mode 100644
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/feature_request.md
@@ -0,0 +1,20 @@
+---
+name: Feature request
+about: Suggest an idea for this project
+title: ''
+labels: ''
+assignees: ''
+
+---
+
+**Is your feature request related to a problem? Please describe.**
+A clear and concise description of what the problem is. Ex. I'm always 
frustrated when [...]
+
+**Describe the solution you'd like**
+A clear and concise description of what you want to happen.
+
+**Describe alternatives you've considered**
+A clear and concise description of any alternative solutions or features 
you've considered.
+
+**Additional context**
+Add any other context or screenshots about the feature request here.
diff --git a/.hgtags b/.hgtags
--- a/.hgtags
+++ b/.hgtags
@@ -783,3 +783,9 @@ bb157905ecb86908dcfb112d102a8c6152557b5d
 94231c85384d893701beeeb69996f57c70fade4d Oct2020_root
 017e44827765fb819d31faefcdf9066dfe593f04 Oct2020_1
 017e44827765fb819d31faefcdf9066dfe593f04 Oct2020_release
+cb4b3f021774b60ffd84c3004d341ec04de736f3 Oct2020_3
+017e44827765fb819d31faefcdf9066dfe593f04 Oct2020_release
+cb4b3f021774b60ffd84c3004d341ec04de736f3 Oct2020_release
+bd91504a03736565fb2dff13cd4c94c738e81aa0 Oct2020_5
+cb4b3f021774b60ffd84c3004d341ec04de736f3 Oct2020_release
+bd91504a03736565fb2dff13cd4c94c738e81aa0 Oct2020_release
diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md
new file mode 100644
--- /dev/null
+++ b/CODE_OF_CONDUCT.md
@@ -0,0 +1,76 @@
+# Contributor Covenant Code of Conduct
+
+## Our Pledge
+
+In the interest of fostering an open and welcoming environment, we as
+contributors and maintainers pledge to making participation in our project and
+our community a harassment-free experience for everyone, regardless of age, 
body
+size, disability, ethnicity, sex characteristics, gender identity and 
expression,
+level of experience, education, socio-economic status, nationality, personal
+appearance, race, religion, or sexual identity and orientation.
+
+## Our Standards
+
+Examples of behavior that contributes to creating a positive environment
+include:
+
+* Using welcoming and inclusive language
+* Being respectful of differing viewpoints and experiences
+* Gracefully accepting constructive criticism
+* Focusing on what is best for the community
+* Showing empathy towards other community members
+
+Examples of unacceptable behavior by participants include:
+
+* The use of sexualized language or imagery and unwelcome sexual attention or

MonetDB: unlock - Merge with default branch.

2020-10-06 Thread Sjoerd Mullender
Changeset: 2d7195debd86 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=2d7195debd86
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
gdk/gdk_heap.c
monetdb5/modules/atoms/str.c
monetdb5/modules/kernel/bat5.c
monetdb5/modules/kernel/batstr.c
monetdb5/modules/mal/CMakeLists.txt
monetdb5/modules/mal/batcalc.c
monetdb5/modules/mal/remote.c
monetdb5/optimizer/opt_prelude.c
monetdb5/optimizer/opt_prelude.h
sql/backends/monet5/UDF/udf/udf.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql.mal
sql/backends/monet5/sql_result.c
sql/backends/monet5/sql_result.h
sql/backends/monet5/sql_scenario.c
sql/backends/monet5/sql_upgrades.c
sql/common/sql_types.c
sql/server/rel_optimizer.c
sql/server/rel_updates.c
sql/server/sql_parser.y
sql/server/sql_scan.c
sql/test/emptydb/Tests/check.stable.out
sql/test/emptydb/Tests/check.stable.out.32bit
sql/test/emptydb/Tests/check.stable.out.int128
sql/test/miscellaneous/Tests/groupby_error.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
tools/merovingian/daemon/controlrunner.c
tools/monetdbe/monetdbe.c
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 48764 to 300 lines):

diff --git a/.hgtags b/.hgtags
--- a/.hgtags
+++ b/.hgtags
@@ -781,3 +781,5 @@ bb157905ecb86908dcfb112d102a8c6152557b5d
 1e3bd8cd485a0880a7557aa5307e986a210a1e00 Jun2020_SP1_release
 bb157905ecb86908dcfb112d102a8c6152557b5d Jun2020_SP1_release
 94231c85384d893701beeeb69996f57c70fade4d Oct2020_root
+017e44827765fb819d31faefcdf9066dfe593f04 Oct2020_1
+017e44827765fb819d31faefcdf9066dfe593f04 Oct2020_release
diff --git a/ChangeLog-Archive b/ChangeLog-Archive
--- a/ChangeLog-Archive
+++ b/ChangeLog-Archive
@@ -1,6 +1,30 @@
 # DO NOT EDIT THIS FILE -- MAINTAINED AUTOMATICALLY
 # This file contains past ChangeLog entries
 
+* Mon Aug 10 2020 Ying Zhang  - 11.39.1-20201006
+- Finished a first version of the new monitoring function
+  user_statistics(), which is only intended for the DBAs.
+  For each database user who has logged in during the current mserver5
+  session, it returns
+  "username": login name of the database user,
+  "querycount": the number of queries this user has executed since his/her
+  first login,
+  "totalticks": the total execution time (in microsecond) of the queries ran
+  by this user,
+  "maxquery": the query with the longest execution time (if two queries have
+  the same execution time, the newer overwrites the older),
+  "maxticks": the execution time of the 'maxquery' (in microsecond),
+  "started": the start timestamp of the 'maxquery',
+  "finished": the finish timestamp of the 'maxquery'.
+
+* Wed Jun 10 2020 Sjoerd Mullender  - 11.39.1-20201006
+- Removed support for LiDAR data, that is the SQL procedures
+  sys.lidarattach, sys.lidarload, and sys.lidarexport.
+
+* Thu Apr  2 2020 Martin Kersten  - 11.39.1-20201006
+- The sys.queue() has been turned into a circular buffer to allow for
+  inspection of both active, paused and recently executed queries.
+
 * Mon Apr 20 2020 Sjoerd Mullender  - 11.37.1-20200511
 - A new system to deal with debug output has been implemented.  There is
   now an option --dbtrace to mserver5 that takes a file argument to which
diff --git a/ChangeLog.Jun2020 b/ChangeLog.Jun2020
deleted file mode 100644
--- a/ChangeLog.Jun2020
+++ /dev/null
@@ -1,3 +0,0 @@
-# ChangeLog file for devel
-# This file is updated with Maddlog
-
diff --git a/ChangeLog.Oct2020 b/ChangeLog.Oct2020
--- a/ChangeLog.Oct2020
+++ b/ChangeLog.Oct2020
@@ -1,27 +1,3 @@
 # ChangeLog file for devel
 # This file is updated with Maddlog
 
-* Mon Aug 10 2020 Ying Zhang 
-- Finished a first version of the new monitoring function
-  user_statistics(), which is only intended for the DBAs.
-  For each database user who has logged in during the current mserver5
-  session, it returns
-  "username": login name of the database user,
-  "querycount": the number of queries this user has executed since his/her
-  first login,
-  "totalticks": the total execution time (in microsecond) of the queries ran
-  by this user,
-  "maxquery": the query with the longest execution time (if two queries have
-  the same execution time, the newer overwrites the older),
-  "maxticks": the execution time of the 'maxquery' (in microsecond),
-  "started": the start timestamp of the 'maxquery',
-  "finished": the finish timestamp of the 'maxquery'.
-
-* Wed Jun 10 2020 Sjoerd Mullender 
-- Removed support for LiDAR data, that is the SQL procedures
-  sys.lidarattach, sys.lidarload, and sys.lidarexport.
-
-* Thu Apr  2 2020 Martin Kersten 
--

MonetDB: unlock - Merge with default branch.

2020-09-15 Thread Sjoerd Mullender
Changeset: 54f283cbba99 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=54f283cbba99
Modified Files:
clients/Tests/exports.stable.out
gdk/gdk_calc.c
monetdb5/modules/kernel/batstr.c
monetdb5/optimizer/Tests/inline08.stable.out
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql_statement.c
sql/server/rel_updates.c
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 1638 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
@@ -294,6 +294,7 @@ macro(monetdb_configure_sizes)
   check_type_size(short SIZEOF_SHORT LANGUAGE C)
   check_type_size(int SIZEOF_INT LANGUAGE C)
   check_type_size(long SIZEOF_LONG LANGUAGE C)
+  check_type_size("long int" SIZEOF_LONG_INT LANGUAGE C)
   check_type_size(double SIZEOF_DOUBLE LANGUAGE C)
   check_type_size(wchar_t SIZEOF_WCHAR_T LANGUAGE C)
   check_type_size(socklen_t HAVE_SOCKLEN_T LANGUAGE C)
diff --git a/gdk/gdk_calc.c b/gdk/gdk_calc.c
--- a/gdk/gdk_calc.c
+++ b/gdk/gdk_calc.c
@@ -5617,6 +5617,133 @@ mul_##TYPE1##_##TYPE2##_##TYPE3(const TY
return nils;\
 }
 
+#ifdef TRUNCATE_NUMBERS
+#define roundflt(x)(x)
+#define rounddbl(x)(x)
+#else
+#define roundflt(x)roundf(x)
+#define rounddbl(x)round(x)
+#endif
+
+#define absbte(x)  abs(x)
+#define abssht(x)  abs(x)
+#define absint(x)  abs(x)
+#define abslng(x)  llabs(x)
+#define abshge(x)  ABSOLUTE(x)
+
+#define MUL_INT_FLT_INT(TYPE1, TYPE2, TYPE3)   \
+static BUN \
+mul_##TYPE1##_##TYPE2##_##TYPE3(   \
+   const TYPE1 *lft, bool incr1, const TYPE2 *rgt, bool incr2, \
+   TYPE3 *restrict dst, TYPE3 max, \
+   struct canditer *restrict ci1, struct canditer *restrict ci2,   \
+   oid candoff1, oid candoff2, bool abort_on_error)\
+{  \
+   BUN nils = 0;   \
+   BUN i = 0, j = 0;   \
+   \
+   if (ci1->tpe == cand_dense && ci2->tpe == cand_dense) { \
+   for (BUN k = 0; k < ci1->ncand; k++) {  \
+   if (incr1)  \
+   i = canditer_next_dense(ci1) - candoff1; \
+   if (incr2)  \
+   j = canditer_next_dense(ci2) - candoff2; \
+   if (is_##TYPE1##_nil(lft[i]) || 
is_##TYPE2##_nil(rgt[j])) { \
+   dst[k] = TYPE3##_nil;   \
+   nils++; \
+   } else if (lft[i] == 0 || rgt[j] == 0) {\
+   dst[k] = 0; \
+   } else if (max / fabs(rgt[j]) < abs##TYPE1(lft[i])) { \
+   if (abort_on_error) \
+   ON_OVERFLOW(TYPE1, TYPE2, "*"); \
+   dst[k] = TYPE3##_nil;   \
+   nils++; \
+   } else {\
+   double m = lft[i] * rgt[j]; \
+   dst[k] = (TYPE3) rounddbl(m);   \
+   }   \
+   }   \
+   } else {\
+   for (BUN k = 0; k < ci1->ncand; k++) {  \
+   if (incr1)  \
+   i = canditer_next(ci1) - candoff1;  \
+   if (incr2)  \
+   j = canditer_next(ci2) - candoff2;  \
+   if (is_##TYPE1##_nil(lft[i]) || 
is_##TYPE2##_nil(rgt[j])) { \
+   dst[k] = TYPE3##_nil;   \
+   nils++; \
+   } else if (lft[i] == 0 || rgt[j] == 0) {\
+   dst[k] = 0; \
+   } else if (max / fabs(rgt[j]) < abs##TYPE1(lft[i])) { \
+   if (abort_on_error)  

MonetDB: unlock - Merge with default branch.

2020-09-15 Thread Sjoerd Mullender
Changeset: 8f0ed6e64146 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=8f0ed6e64146
Modified Files:
ChangeLog
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
gdk/gdk.h
gdk/gdk_align.c
gdk/gdk_bat.c
gdk/gdk_bbp.c
gdk/gdk_bbp.h
gdk/gdk_calc.c
gdk/gdk_group.c
gdk/gdk_hash.c
gdk/gdk_heap.c
gdk/gdk_imprints.c
gdk/gdk_join.c
gdk/gdk_logger.c
gdk/gdk_logger_old.c
gdk/gdk_orderidx.c
gdk/gdk_private.h
gdk/gdk_storage.c
gdk/gdk_tm.c
geom/monetdb5/geom.c
monetdb5/mal/mal_authorize.c
monetdb5/mal/mal_profiler.c
monetdb5/modules/kernel/bat5.c
monetdb5/modules/kernel/batstr.c
monetdb5/modules/mal/pcre.c
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql.h
sql/backends/monet5/sql_cat.c
sql/backends/monet5/sql_gencode.c
sql/backends/monet5/sql_result.c
sql/backends/monet5/sql_scenario.c
sql/backends/monet5/sql_statement.c
sql/include/sql_catalog.h
sql/include/sql_relation.h
sql/server/rel_optimizer.c
sql/storage/bat/bat_storage.c
sql/test/BugTracker-2014/Tests/manifold.Bug-3556.stable.out

sql/test/FeatureRequests/Tests/foreign_key_outer_join_dead_code_elimination-explain-0join-view.stable.out

sql/test/FeatureRequests/Tests/foreign_key_outer_join_dead_code_elimination-explain-1join-query.stable.out

sql/test/FeatureRequests/Tests/foreign_key_outer_join_dead_code_elimination-explain-1join-view.stable.out

sql/test/FeatureRequests/Tests/foreign_key_outer_join_dead_code_elimination-explain-2join-query.stable.out

sql/test/FeatureRequests/Tests/foreign_key_outer_join_dead_code_elimination-explain-2join-view.stable.out
sql/test/miscellaneous/Tests/groupby_error.stable.out
tools/monetdbe/monetdbe.c
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 11918 to 300 lines):

diff --git a/ChangeLog.Oct2020 b/ChangeLog.Oct2020
--- a/ChangeLog.Oct2020
+++ b/ChangeLog.Oct2020
@@ -1,6 +1,22 @@
 # ChangeLog file for devel
 # This file is updated with Maddlog
 
+* Mon Aug 10 2020 Ying Zhang 
+- Finished a first version of the new monitoring function
+  user_statistics(), which is only intended for the DBAs.
+  For each database user who has logged in during the current mserver5
+  session, it returns
+  "username": login name of the database user,
+  "querycount": the number of queries this user has executed since his/her
+  first login,
+  "totalticks": the total execution time (in microsecond) of the queries ran
+  by this user,
+  "maxquery": the query with the longest execution time (if two queries have
+  the same execution time, the newer overwrites the older),
+  "maxticks": the execution time of the 'maxquery' (in microsecond),
+  "started": the start timestamp of the 'maxquery',
+  "finished": the finish timestamp of the 'maxquery'.
+
 * Wed Jun 10 2020 Sjoerd Mullender 
 - Removed support for LiDAR data, that is the SQL procedures
   sys.lidarattach, sys.lidarload, and sys.lidarexport.
diff --git a/ChangeLog.userstats b/ChangeLog.userstats
deleted file mode 100644
--- a/ChangeLog.userstats
+++ /dev/null
@@ -1,19 +0,0 @@
-# ChangeLog file for userstats
-# This file is updated with Maddlog
-
-* Mon Aug 10 2020 Ying Zhang 
-- Finished a first version of the new monitoring function
-  user_statistics(), which is only intended for the DBAs.
-  For each database user who has logged in during the current mserver5
-  session, it returns 
-  "username": login name of the database user,
-  "querycount": the number of queries this user has executed since his/her
-  first login,
-  "totalticks": the total execution time (in microsecond) of the queries ran
-  by this user,
-  "maxquery": the query with the longest execution time (if two queries have
-  the same execution time, the newer overwrites the older),
-  "maxticks": the execution time of the 'maxquery' (in microsecond),
-  "started": the start timestamp of the 'maxquery',
-  "finished": the finish timestamp of the 'maxquery'.
-
diff --git a/MonetDB.spec b/MonetDB.spec
--- a/MonetDB.spec
+++ b/MonetDB.spec
@@ -116,9 +116,14 @@ BuildRequires: gcc
 BuildRequires: bison
 BuildRequires: /usr/bin/python3
 %if %{?rhel:1}%{!?rhel:0}
+# RH 7 (and for readline also 8)
 BuildRequires: bzip2-devel
+BuildRequires: unixODBC-devel
+BuildRequires: readline-devel
 %else
 BuildRequires: pkgconfig(bzip2)
+BuildRequires: pkgconfig(odbc)
+BuildRequires: pkgconfig(readline)
 %endif
 %if %{with fits}
 BuildRequires: pkgconfig(cfitsio)
@@ -128,23 +133,19 @@ BuildRequires: geos-devel >= 3.4.0
 %endif
 BuildRequires: pkgconfig(libcurl)
 BuildRequires: pkgconfig(libl

MonetDB: unlock - Merge with default branch.

2020-09-02 Thread Sjoerd Mullender
Changeset: f117137a0700 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=f117137a0700
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
monetdb5/modules/kernel/algebra.c
monetdb5/modules/kernel/algebra.mal
sql/server/rel_optimizer.c
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 722 to 300 lines):

diff --git a/clients/Tests/MAL-signatures.stable.out 
b/clients/Tests/MAL-signatures.stable.out
--- a/clients/Tests/MAL-signatures.stable.out
+++ b/clients/Tests/MAL-signatures.stable.out
@@ -113,12 +113,12 @@ stdout of test 'MAL-signatures` in direc
 [ "aggr",  "corr", "command aggr.corr(X_1:bat[:any_2], 
X_2:bat[:any_2]):dbl ", "ALGcorr;", ""  ]
 [ "aggr",  "count","command aggr.count(X_1:bat[:any_1], 
X_2:bat[:oid], X_3:bat[:any_2], X_4:bit):bat[:lng] ",  "AGGRcount3;",  ""   
   ]
 [ "aggr",  "count","command aggr.count(X_1:bat[:any_1], 
X_2:bat[:oid], X_3:bat[:any_2]):bat[:lng] ",   "AGGRcount3nils;",  ""   
   ]
-[ "aggr",  "count","command aggr.count(X_1:bat[:any], 
X_2:bat[:oid]):lng ","ALGcountCND_bat;", ""  ]
-[ "aggr",  "count","command aggr.count(X_1:bat[:any], 
X_2:bat[:oid], X_3:bit):lng ",   "ALGcountCND_nil;", ""  ]
+[ "aggr",  "count","command aggr.count(X_1:bat[:any], 
X_2:bat[:cnd]):lng ","ALGcountCND_bat;", ""  ]
+[ "aggr",  "count","command aggr.count(X_1:bat[:any], 
X_2:bat[:cnd], X_3:bit):lng ",   "ALGcountCND_nil;", ""  ]
 [ "aggr",  "count","command aggr.count(X_1:bat[:any]):lng ",   
"ALGcount_bat;",""  ]
 [ "aggr",  "count","command aggr.count(X_1:bat[:any], X_2:bit):lng 
",  "ALGcount_nil;",""  ]
 [ "aggr",  "count_no_nil", "command aggr.count_no_nil(X_1:bat[:any_1], 
X_2:bat[:oid], X_3:bat[:any_2]):bat[:lng] ","AGGRcount3nonils;",""  
]
-[ "aggr",  "count_no_nil", "command aggr.count_no_nil(X_1:bat[:any_2], 
X_2:bat[:oid]):lng ",   "ALGcountCND_no_nil;",  ""  ]
+[ "aggr",  "count_no_nil", "command aggr.count_no_nil(X_1:bat[:any_2], 
X_2:bat[:cnd]):lng ",   "ALGcountCND_no_nil;",  ""  ]
 [ "aggr",  "count_no_nil", "command aggr.count_no_nil(X_1:bat[:any_2]):lng 
",  "ALGcount_no_nil;", ""  ]
 [ "aggr",  "covariance",   "command aggr.covariance(X_1:bat[:bte], 
X_2:bat[:bte], X_3:bat[:oid], X_4:bat[:any_1]):bat[:dbl] ", 
"AGGRcovariance;",  ""  ]
 [ "aggr",  "covariance",   "command aggr.covariance(X_1:bat[:dbl], 
X_2:bat[:dbl], X_3:bat[:oid], X_4:bat[:any_1]):bat[:dbl] ", 
"AGGRcovariance;",  ""  ]
@@ -667,10 +667,10 @@ stdout of test 'MAL-signatures` in direc
 [ "algebra",   "outerjoin","command algebra.outerjoin(X_1:bat[:any_1], 
X_2:bat[:any_1], X_3:bat[:cnd], X_4:bat[:cnd], X_5:bit, X_6:lng):bat[:oid] ",   
"ALGouterjoin1;",   ""  ]
 [ "algebra",   "outerjoin","command algebra.outerjoin(X_2:bat[:any_1], 
X_3:bat[:any_1], X_4:bat[:cnd], X_5:bat[:cnd], X_6:bit, X_7:lng) 
(X_0:bat[:oid], X_1:bat[:oid]) ",  "ALGouterjoin;",""  ]
 [ "algebra",   "project",  "pattern algebra.project(X_1:bat[:any_1], 
X_2:any_3):bat[:any_3] ", "ALGprojecttail;",  ""  ]
+[ "algebra",   "projection",   "command algebra.projection(X_1:bat[:msk], 
X_2:bat[:any_3], X_3:bat[:any_3]):bat[:any_3] ", "ALGprojection2;",  "" 
 ]
+[ "algebra",   "projection",   "command algebra.projection(X_1:bat[:oid], 
X_2:bat[:any_3], X_3:bat[:any_3]):bat[:any_3] ", "ALGprojection2;",  "" 
 ]
 [ "algebra",   "projection",   "command algebra.projection(X_1:bat[:msk], 
X_2:bat[:any_3]):bat[:any_3] ",  "ALGprojection;",   ""  ]
 [ "algebra",   "projection",   "command algebra.projection(X_1:bat[:oid], 
X_2:bat[:any_3]):bat[:any_3] ",  "ALGprojection;",   ""  ]
-[ "algebra",   "projection2",  "command algebra.projection2(X_1:bat[:msk], 
X_2:bat[:any_3], X_3:bat[:any_3]):bat[:any_3] ","ALGprojection2;",  ""  
]
-[ "algebra",   "projection2",  "command algebra.projection2(X_1:bat[:oid], 
X_2:bat[:any_3], X_3:bat[:any_3]):bat[:any_3] ","ALGprojection2;",  ""  
]
 [ "algebra",   "projectionpath",   "pattern 
algebra.projectionpath(X_1:bat[:any]...):bat[:any] ",  "ALGprojectionpath;",   
""  ]
 [ "algebra",   "rangejoin","command algebra.rangejoin(X_1:bat[:any_1], 
X_2:bat[:any_1], X_3:bat[:any_1], X_4:bat[:cnd], X_5:bat[:cnd], X_6:bit, 
X_7:bit, X_8:bit, X_9:bit, X_10:lng):bat[:oid] ",  "ALGrangejoin1;",   ""   
   ]
 [ "algebra",   "rangejoin","command algebra.rangejoin(X_2:bat[:any_1], 
X_3:bat[:any_1], X_4:bat[:any_1], X_5:bat[:cnd], X_6:bat[:cnd], X_7:bit, 
X_8:bit, X_9:bit, X_10:bit, X_11:lng) (X_0:bat[:oid], X_1

MonetDB: unlock - Merge with default branch.

2020-09-01 Thread Sjoerd Mullender
Changeset: 491d4b6c90da for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=491d4b6c90da
Modified Files:
clients/Tests/exports.stable.out
gdk/gdk.h
gdk/gdk_batop.c
geom/monetdb5/geom.c
monetdb5/modules/kernel/algebra.c
monetdb5/modules/kernel/bat5.c
monetdb5/modules/mal/pcre.c
monetdb5/modules/mal/remote.c
monetdb5/optimizer/opt_pushselect.c
sql/backends/monet5/sql.c
sql/server/rel_optimizer.c
sql/test/emptydb/Tests/check.stable.out
sql/test/emptydb/Tests/check.stable.out.32bit
sql/test/emptydb/Tests/check.stable.out.int128
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 126896 to 300 lines):

diff --git a/clients/Tests/exports.stable.out b/clients/Tests/exports.stable.out
--- a/clients/Tests/exports.stable.out
+++ b/clients/Tests/exports.stable.out
@@ -119,7 +119,7 @@ gdk_return BATclear(BAT *b, bool force);
 void BATcommit(BAT *b, BUN size);
 BAT *BATconstant(oid hseq, int tt, const void *val, BUN cnt, role_t role);
 BAT *BATconvert(BAT *b, BAT *s, int tp, bool abort_on_error, uint8_t scale1, 
uint8_t scale2, uint8_t precision);
-BUN BATcount_no_nil(BAT *b);
+BUN BATcount_no_nil(BAT *b, BAT *s);
 gdk_return BATdel(BAT *b, BAT *d) __attribute__((__warn_unused_result__));
 BAT *BATdense(oid hseq, oid tseq, BUN cnt) 
__attribute__((__warn_unused_result__));
 BAT *BATdiff(BAT *l, BAT *r, BAT *sl, BAT *sr, bool nil_matches, bool not_in, 
BUN estimate);
diff --git a/common/stream/Tests/All b/common/stream/Tests/All
--- a/common/stream/Tests/All
+++ b/common/stream/Tests/All
@@ -10,7 +10,7 @@ HAVE_LIBZ?write_gz
 HAVE_LIBLZ4&HAVE_PYTHON_LZ4?write_lz4
 HAVE_LIBLZMA?write_xz
 
-urlstream
+HAVE_CURL?urlstream
 read_iconv
 write_iconv
 
diff --git a/common/stream/Tests/read_bz2.py b/common/stream/Tests/read_bz2.py
--- a/common/stream/Tests/read_bz2.py
+++ b/common/stream/Tests/read_bz2.py
@@ -1,7 +1,8 @@
 #!/usr/bin/env python3
 
+import sys, os
+sys.path.append(os.environ.get('TSTSRCDIR','.'))
 import read_tests
-import sys
 
 
 def filter(f):
diff --git a/common/stream/Tests/read_gz.py b/common/stream/Tests/read_gz.py
--- a/common/stream/Tests/read_gz.py
+++ b/common/stream/Tests/read_gz.py
@@ -1,7 +1,8 @@
 #!/usr/bin/env python3
 
+import sys, os
+sys.path.append(os.environ.get('TSTSRCDIR','.'))
 import read_tests
-import sys
 
 
 def filter(f):
diff --git a/common/stream/Tests/read_iconv.py 
b/common/stream/Tests/read_iconv.py
--- a/common/stream/Tests/read_iconv.py
+++ b/common/stream/Tests/read_iconv.py
@@ -1,10 +1,10 @@
 #!/usr/bin/env python3
 
+import sys, os
+sys.path.append(os.environ.get('TSTSRCDIR','.'))
 from testdata import Doc, TestFile
 
-import os
 import subprocess
-import sys
 
 
 def run_streamcat(text, enc, expected_error = None):
@@ -20,7 +20,10 @@ def run_streamcat(text, enc, expected_er
 cmd = ['streamcat', 'read', filename, 'rstream', f'iconv:{enc}']
 print(f"Input is {repr(content)}")
 proc = subprocess.run(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
+if proc.stdout:
+proc.stdout = proc.stdout.replace(b'\r', b'')
 if proc.stderr:
+proc.stderr = proc.stderr.replace(b'\r', b'')
 sys.stderr.buffer.write(proc.stderr)
 sys.stderr.flush()
 if expected_error == None:
@@ -49,4 +52,3 @@ run_streamcat(text, 'latin1')
 
 # invalid utf-8, expect an error
 run_streamcat(b"M\xc3\xc3NETDB", 'utf-8', b'multibyte sequence')
-
diff --git a/common/stream/Tests/read_lz4.py b/common/stream/Tests/read_lz4.py
--- a/common/stream/Tests/read_lz4.py
+++ b/common/stream/Tests/read_lz4.py
@@ -1,7 +1,8 @@
 #!/usr/bin/env python3
 
+import sys, os
+sys.path.append(os.environ.get('TSTSRCDIR','.'))
 import read_tests
-import sys
 
 
 def filter(f):
diff --git a/common/stream/Tests/read_uncompressed.py 
b/common/stream/Tests/read_uncompressed.py
--- a/common/stream/Tests/read_uncompressed.py
+++ b/common/stream/Tests/read_uncompressed.py
@@ -1,7 +1,8 @@
 #!/usr/bin/env python3
 
+import sys, os
+sys.path.append(os.environ.get('TSTSRCDIR','.'))
 import read_tests
-import sys
 
 
 def filter(f):
diff --git a/common/stream/Tests/read_xz.py b/common/stream/Tests/read_xz.py
--- a/common/stream/Tests/read_xz.py
+++ b/common/stream/Tests/read_xz.py
@@ -1,7 +1,8 @@
 #!/usr/bin/env python3
 
+import sys, os
+sys.path.append(os.environ.get('TSTSRCDIR','.'))
 import read_tests
-import sys
 
 
 def filter(f):
diff --git a/common/stream/Tests/write_bz2.py b/common/stream/Tests/write_bz2.py
--- a/common/stream/Tests/write_bz2.py
+++ b/common/stream/Tests/write_bz2.py
@@ -1,7 +1,8 @@
 #!/usr/bin/env python3
 
+import sys, os
+sys.path.append(os.environ.get('TSTSRCDIR','.'))
 import write_tests
-import sys
 
 
 def filter(f):
diff --git a/common/stream/Tests/write_gz.py b/common/stream/Tests/write_gz.py
--- a/common/stream/Tests/write_gz.py
+++ b/common/stream/Tests/write_gz.py
@@ -1,7 +1,8 @@
 #!/usr/bin/env pyth

MonetDB: unlock - Merge with default branch.

2020-08-24 Thread Sjoerd Mullender
Changeset: 42aca56dd9f3 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=42aca56dd9f3
Modified Files:
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql_upgrades.c
sql/server/rel_optimizer.c
sql/test/miscellaneous/Tests/groupby_error.stable.out
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 2446 to 300 lines):

diff --git a/.bumpversion.cfg b/.bumpversion.cfg
--- a/.bumpversion.cfg
+++ b/.bumpversion.cfg
@@ -1,5 +1,5 @@
 [bumpversion]
-current_version = 11.38.0
+current_version = 11.40.0
 commit = False
 tag = False
 
@@ -11,10 +11,6 @@ serialize = set(MONETDB_VERSION_MAJOR "{
 search = %global version {current_version}
 replace = %global version {new_version}
 
-[bumpversion:file:NT/rules.msc]
-
-[bumpversion:file:NT/monetdb_config.h.in]
-
 [bumpversion:file:gdk/libbat.rc]
 parse = (?P\d+),(?P\d+),(?P\d+)
 serialize = {major},{minor},{patch}
@@ -34,3 +30,4 @@ serialize = {major},{minor},{patch}
 [bumpversion:file:monetdb5/tools/libmonetdb5.rc]
 parse = (?P\d+),(?P\d+),(?P\d+)
 serialize = {major},{minor},{patch}
+
diff --git a/.hgtags b/.hgtags
--- a/.hgtags
+++ b/.hgtags
@@ -780,3 +780,4 @@ 1e3bd8cd485a0880a7557aa5307e986a210a1e00
 bb157905ecb86908dcfb112d102a8c6152557b5d Jun2020_11
 1e3bd8cd485a0880a7557aa5307e986a210a1e00 Jun2020_SP1_release
 bb157905ecb86908dcfb112d102a8c6152557b5d Jun2020_SP1_release
+94231c85384d893701beeeb69996f57c70fade4d Oct2020_root
diff --git a/ChangeLog b/ChangeLog
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,11 +1,3 @@
 # ChangeLog file for devel
 # This file is updated with Maddlog
 
-* Wed Jun 10 2020 Sjoerd Mullender 
-- Removed support for LiDAR data, that is the SQL procedures
-  sys.lidarattach, sys.lidarload, and sys.lidarexport.
-
-* Thu Apr  2 2020 Martin Kersten 
-- The sys.queue() has been turned into a circular buffer to allow for
-  inspection of both active, paused and recently executed queries.
-
diff --git a/ChangeLog b/ChangeLog.Oct2020
copy from ChangeLog
copy to ChangeLog.Oct2020
diff --git a/MonetDB.spec b/MonetDB.spec
--- a/MonetDB.spec
+++ b/MonetDB.spec
@@ -1,5 +1,5 @@
 %global name MonetDB
-%global version 11.38.0
+%global version 11.40.0
 %{!?buildno: %global buildno %(date +%Y%m%d)}
 
 # Use bcond_with to add a --with option; i.e., "without" is default.
diff --git a/clients/ChangeLog b/clients/ChangeLog.Oct2020
copy from clients/ChangeLog
copy to clients/ChangeLog.Oct2020
diff --git a/clients/mapiclient/ReadlineTools.c 
b/clients/mapiclient/ReadlineTools.c
--- a/clients/mapiclient/ReadlineTools.c
+++ b/clients/mapiclient/ReadlineTools.c
@@ -291,10 +291,6 @@ continue_completion(rl_completion_func_t
rl_attempted_completion_function = func;
 }
 
-#ifndef BUFSIZ
-#define BUFSIZ 1024
-#endif
-
 static void
 readline_show_error(const char *msg) {
rl_save_prompt();
@@ -303,13 +299,19 @@ readline_show_error(const char *msg) {
rl_clear_message();
 }
 
+#ifndef BUFFER_SIZE
+#define BUFFER_SIZE 1024
+#endif
+
 static int
 invoke_editor(int cnt, int key) {
char template[] = "/tmp/mclient_temp_XX";
-   char cmd[BUFSIZ];
-   char *editor;
+   char editor_command[BUFFER_SIZE];
+   char *read_buff = NULL;
+   char *editor = NULL;
FILE *fp;
-   size_t cmd_len;
+   size_t content_len;
+   size_t read_bytes, idx;
 
(void) cnt;
(void) key;
@@ -324,35 +326,64 @@ invoke_editor(int cnt, int key) {
fflush(fp);
 
editor = getenv("VISUAL");
-   if (!editor) {
+   if (editor == NULL) {
editor = getenv("EDITOR");
-   if (!editor) {
+   if (editor == NULL) {
readline_show_error("invoke_editor: EDITOR/VISUAL env 
variable not set\n");
goto bailout;
}
}
 
-   snprintf(cmd, BUFSIZ, "%s %s", editor, template);
-   if (system(cmd) != 0) {
+   snprintf(editor_command, BUFFER_SIZE, "%s %s", editor, template);
+   if (system(editor_command) != 0) {
readline_show_error("invoke_editor: Starting editor failed\n");
goto bailout;
}
 
-   fseek(fp, 0, SEEK_SET);
-   cmd_len = fread(cmd, sizeof(char), BUFSIZ, fp);
-   fclose(fp);
+   fseek(fp, 0L, SEEK_END);
+   content_len = ftell(fp);
+   rewind(fp);
+
+   if (content_len > 0) {
+   read_buff = (char *)malloc(content_len*sizeof(char));
+   if (read_buff == NULL) {
+   readline_show_error("invoke_editor: Cannot allocate 
memory\n");
+   goto bailout;
+   }
+
+   read_bytes = fread(read_buff, sizeof(char), content_len, fp);
+   if (read_bytes != content_len) {
+   readline_show_error("invoke_editor: Did not read from 
file correctly\n");
+   goto bailout;
+   }
 
-   *(cmd + cmd_len) = 0;
+ 

MonetDB: unlock - Merge with default branch.

2020-08-21 Thread Sjoerd Mullender
Changeset: 700ef34601e0 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=700ef34601e0
Modified Files:
clients/Tests/exports.stable.out
gdk/gdk_logger.c
monetdb5/mal/mal_profiler.c
monetdb5/modules/mal/remote.c
monetdb5/modules/mal/tablet.c
monetdb5/modules/mal/tokenizer.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql_result.c
sql/backends/monet5/sql_scenario.c
sql/backends/monet5/wlr.c
sql/server/rel_updates.c
sql/server/sql_scan.c
sql/storage/bat/bat_logger.c
sql/storage/store.c
sql/test/sys-schema/Tests/systemfunctions.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 23400 to 300 lines):

diff --git a/clients/Tests/exports.stable.out b/clients/Tests/exports.stable.out
--- a/clients/Tests/exports.stable.out
+++ b/clients/Tests/exports.stable.out
@@ -1877,25 +1877,29 @@ char *buffer_get_buf(buffer *b);
 void buffer_init(buffer *restrict b, char *restrict buf, size_t size);
 stream *buffer_rastream(buffer *restrict b, const char *restrict name);
 stream *buffer_wastream(buffer *restrict b, const char *restrict name);
+stream *bz2_stream(stream *inner, int preset);
 stream *callback_stream(void *restrict priv, ssize_t (*read)(void *restrict 
priv, void *restrict buf, size_t elmsize, size_t cnt), ssize_t (*write)(void 
*restrict priv, const void *restrict buf, size_t elmsize, size_t cnt), void 
(*close)(void *priv), void (*destroy)(void *priv), const char *restrict name);
 void close_stream(stream *s);
-stream *file_rastream(FILE *restrict fp, const char *restrict name);
-stream *file_rstream(FILE *restrict fp, const char *restrict name);
-stream *file_wastream(FILE *restrict fp, const char *restrict name);
-stream *file_wstream(FILE *restrict fp, const char *restrict name);
+stream *compressed_stream(stream *inner, int preset);
+stream *create_text_stream(stream *s);
+stream *file_rstream(FILE *restrict fp, bool binary, const char *restrict 
name);
+stream *file_wstream(FILE *restrict fp, bool binary, const char *restrict 
name);
 FILE *getFile(stream *s);
 int getFileNo(stream *s);
 size_t getFileSize(stream *s);
+stream *gz_stream(stream *inner, int preset);
 stream *iconv_rstream(stream *restrict ss, const char *restrict charset, const 
char *restrict name);
 stream *iconv_wstream(stream *restrict ss, const char *restrict charset, const 
char *restrict name);
 bool isa_block_stream(const stream *s);
+stream *lz4_stream(stream *inner, int preset);
 void mnstr_clearerr(stream *s);
 void mnstr_close(stream *s);
 void mnstr_destroy(stream *s);
-int mnstr_errnr(const stream *s);
+mnstr_error_kind mnstr_errnr(const stream *s);
 char *mnstr_error(const stream *s);
+const char *mnstr_error_kind_name(mnstr_error_kind k);
 int mnstr_fgetpos(stream *restrict s, fpos_t *restrict p);
-int mnstr_flush(stream *s);
+int mnstr_flush(stream *s, mnstr_flush_level flush_level);
 int mnstr_fsetpos(stream *restrict s, fpos_t *restrict p);
 int mnstr_fsync(stream *s);
 buffer *mnstr_get_buffer(stream *s);
@@ -1904,6 +1908,7 @@ int mnstr_init(int embedded);
 int mnstr_isalive(const stream *s);
 bool mnstr_isbinary(const stream *s);
 char *mnstr_name(const stream *s);
+const char *mnstr_peek_error(const stream *s);
 int mnstr_printf(stream *restrict s, _In_z_ _Printf_format_string_ const char 
*restrict format, ...) __attribute__((__format__(__printf__, 2, 3)));
 ssize_t mnstr_read(stream *restrict s, void *restrict buf, size_t elmsize, 
size_t cnt);
 int mnstr_readBte(stream *restrict s, int8_t *restrict val);
@@ -1944,8 +1949,12 @@ stream *open_wastream(const char *filena
 stream *open_wstream(const char *filename);
 stream *socket_rstream(SOCKET socket, const char *name);
 stream *socket_wstream(SOCKET socket, const char *name);
+stream *stderr_wastream(void);
+stream *stdin_rastream(void);
+stream *stdout_wastream(void);
 stream *stream_blackhole_create(void);
 stream *stream_fwf_create(stream *restrict s, size_t num_fields, size_t 
*restrict widths, char filler);
+stream *xz_stream(stream *inner, int preset);
 
 
 # 21:41:06 >  
diff --git a/clients/examples/C/CMakeLists.txt 
b/clients/examples/C/CMakeLists.txt
--- a/clients/examples/C/CMakeLists.txt
+++ b/clients/examples/C/CMakeLists.txt
@@ -37,12 +37,21 @@ if(TESTING)
   target_link_libraries(smack01
 PRIVATE mapi)
 
+  add_executable(streamcat
+streamcat.c)
+
+   target_link_libraries(streamcat
+PRIVATE
+monetdb_config_header
+stream)
+
   install(TARGETS
 sample0
 sample1
 sample4
 smack00
 smack01
+streamcat
 RUNTIME
 DESTINATION
 ${CMAKE_INSTALL_BINDIR}
diff --git a/clients/examples/C/streamcat.c b/clients/examples/C/streamcat.c
new file mode 100644
--- /dev/null
+++ b/clients/examples/C/streamcat.c
@@ -0,0 +1,565 @@
+#include "monetdb_config.h"
+#include "s

MonetDB: unlock - Merge with default branch.

2020-08-20 Thread Sjoerd Mullender
Changeset: 79c92bc589f6 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=79c92bc589f6
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
gdk/gdk_hash.c
monetdb5/extras/mal_optimizer_template/Tests/opt_sql_append.stable.out
monetdb5/mal/mal_parser.c
monetdb5/mal/mal_prelude.c
monetdb5/modules/atoms/json.c
monetdb5/modules/mal/tablet.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql_result.c
sql/backends/monet5/sql_result.h
sql/common/sql_types.c
sql/server/rel_updates.c
sql/server/sql_parser.y
sql/storage/store.c
sql/test/BugTracker-2009/Tests/copy_multiple_files.SF-2902320.stable.out
sql/test/BugTracker-2015/Tests/readonly.Bug-3709.stable.out
sql/test/emptydb/Tests/check.stable.out
sql/test/emptydb/Tests/check.stable.out.32bit
sql/test/emptydb/Tests/check.stable.out.int128
sql/test/sys-schema/Tests/systemfunctions.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
tools/monetdbe/monetdbe.c
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 4587 to 300 lines):

diff --git a/NT/mkodbcwxs.py b/NT/mkodbcwxs.py
--- a/NT/mkodbcwxs.py
+++ b/NT/mkodbcwxs.py
@@ -41,7 +41,14 @@ def main():
 arch = 'x86'
 libcrypto = ''
 vcpkg = r'C:\vcpkg\installed\x86-windows\{}'
-vs = '2019'
+with open('CMakeCache.txt') as cache:
+for line in cache:
+if line.startswith('CMAKE_GENERATOR_INSTANCE:INTERNAL='):
+comdir = line.split('=', 1)[1].strip().replace('/', '\\')
+break
+else:
+comdir = r'C:\Program Files (x86)\Microsoft Visual 
Studio\2019\Community'
+msvc = os.path.join(comdir, r'VC\Redist\MSVC')
 features = []
 print(r'')
 print(r'http://schemas.microsoft.com/wix/2006/wi";>')
@@ -57,7 +64,6 @@ def main():
 print(r'')
 print(r'')
 print(r'')
-msvc = r'C:\Program Files (x86)\Microsoft Visual 
Studio\{}\Community\VC\Redist\MSVC'.format(vs)
 d = sorted(os.listdir(msvc))[-1]
 msm = '_CRT_{}.msm'.format(arch)
 for f in sorted(os.listdir(os.path.join(msvc, d, 'MergeModules'))):
diff --git a/NT/mksqlwxs.py b/NT/mksqlwxs.py
--- a/NT/mksqlwxs.py
+++ b/NT/mksqlwxs.py
@@ -48,7 +48,14 @@ def main():
 arch = 'x86'
 libcrypto = ''
 vcpkg = r'C:\vcpkg\installed\x86-windows\{}'
-vs = '2019'
+with open('CMakeCache.txt') as cache:
+for line in cache:
+if line.startswith('CMAKE_GENERATOR_INSTANCE:INTERNAL='):
+comdir = line.split('=', 1)[1].strip().replace('/', '\\')
+break
+else:
+comdir = r'C:\Program Files (x86)\Microsoft Visual 
Studio\2019\Community'
+msvc = os.path.join(comdir, r'VC\Redist\MSVC')
 features = []
 extend = []
 debug = []
@@ -102,7 +109,6 @@ def main():
 print(r'')
 print(r'')
 print(r'')
-msvc = r'C:\Program Files (x86)\Microsoft Visual 
Studio\{}\Community\VC\Redist\MSVC'.format(vs)
 d = sorted(os.listdir(msvc))[-1]
 msm = '_CRT_{}.msm'.format(arch)
 for f in sorted(os.listdir(os.path.join(msvc, d, 'MergeModules'))):
diff --git a/clients/Tests/MAL-signatures.stable.out 
b/clients/Tests/MAL-signatures.stable.out
--- a/clients/Tests/MAL-signatures.stable.out
+++ b/clients/Tests/MAL-signatures.stable.out
@@ -8450,7 +8450,7 @@ stdout of test 'MAL-signatures` in direc
 [ "sql",   "claim","unsafe pattern sql.claim(X_1:int, X_2:str, 
X_3:str, X_4:lng):lng ","mvc_claim_wrap;",  ""  ]
 [ "sql",   "clear_table",  "unsafe pattern sql.clear_table(X_1:str, 
X_2:str):lng ","mvc_clear_table_wrap;",""  ]
 [ "sql",   "commit",   "unsafe pattern sql.commit():void ",
"SQLcommit;",   ""  ]
-[ "sql",   "copy_from","unsafe pattern sql.copy_from(X_1:ptr, X_2:str, 
X_3:str, X_4:str, X_5:str, X_6:str, X_7:lng, X_8:lng, X_9:int, X_10:str, 
X_11:int):bat[:any]... ",  "mvc_import_table_wrap;",   ""  ]
+[ "sql",   "copy_from","unsafe pattern sql.copy_from(X_1:ptr, X_2:str, 
X_3:str, X_4:str, X_5:str, X_6:str, X_7:lng, X_8:lng, X_9:int, X_10:str, 
X_11:int, X_12:int):bat[:any]... ","mvc_import_table_wrap;",   ""  ]
 [ "sql",   "copy_rejects", "pattern sql.copy_rejects() (X_0:bat[:lng], 
X_1:bat[:int], X_2:bat[:str], X_3:bat[:str]) ", "COPYrejects;", ""  ]
 [ "sql",   "copy_rejects_clear",   "unsafe pattern 
sql.copy_rejects_clear():void ","COPYrejects_clear;",   ""  ]
 [ "sql",   "corr", "pattern sql.corr(X_1:bte, X_2:bte, X_3:lng, 
X_4:lng):dbl ","SQLcorr;", ""  ]
diff --git a/clients/Tests/MAL-signatures.stable.out.int128 
b/clients/Tests/MAL-signat

MonetDB: unlock - Merge with default branch.

2020-08-17 Thread Sjoerd Mullender
Changeset: 503f3d5c8e34 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=503f3d5c8e34
Modified Files:
gdk/gdk_logger.c
gdk/gdk_private.h
monetdb5/mal/Tests/All
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql_result.c
sql/common/sql_types.c
sql/include/sql_catalog.h
sql/test/miscellaneous/Tests/groupby_error.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 1468 to 300 lines):

diff --git a/MonetDB.spec b/MonetDB.spec
--- a/MonetDB.spec
+++ b/MonetDB.spec
@@ -753,7 +753,8 @@ fi
 
 %files selinux
 %defattr(-,root,root,0755)
-%doc buildtools/selinux/*
+%docdir %{_datadir}/doc/MonetDB-selinux
+%{_datadir}/doc/MonetDB-selinux/*
 %{_datadir}/selinux/*/monetdb.pp
 
 %endif
@@ -793,22 +794,6 @@ fi
 
 %cmake3_build
 
-%if %{?rhel:0}%{!?rhel:1} || 0%{?rhel} >= 7
-cd buildtools/selinux
-%if 0%{?fedora} < 27
-# no `map' policy available before Fedora 27
-sed -i '/map/d' monetdb.te
-%endif
-
-for selinuxvariant in %{selinux_variants}
-do
-  make NAME=${selinuxvariant} -f /usr/share/selinux/devel/Makefile
-  mv monetdb.pp monetdb.pp.${selinuxvariant}
-  make NAME=${selinuxvariant} -f /usr/share/selinux/devel/Makefile clean
-done
-cd -
-%endif
-
 %install
 %cmake3_install
 
@@ -836,12 +821,6 @@ rm -f %{buildroot}%{_bindir}/monetdb_mte
 rm -rf %{buildroot}%{_datadir}/monetdb # /cmake
 
 %if %{?rhel:0}%{!?rhel:1} || 0%{?rhel} >= 7
-for selinuxvariant in %{selinux_variants}
-do
-  install -d %{buildroot}%{_datadir}/selinux/${selinuxvariant}
-  install -p -m 644 buildtools/selinux/monetdb.pp.${selinuxvariant} \
-%{buildroot}%{_datadir}/selinux/${selinuxvariant}/monetdb.pp
-done
 if [ -x /usr/sbin/hardlink ]; then
 /usr/sbin/hardlink -cv %{buildroot}%{_datadir}/selinux
 else
diff --git a/NT/mkodbcwxs.py b/NT/mkodbcwxs.py
--- a/NT/mkodbcwxs.py
+++ b/NT/mkodbcwxs.py
@@ -48,11 +48,11 @@ def main():
 print(r'  '.format(upgradecode[arch], sys.argv[1]))
 print(r''.format(arch))
 print(r'')
-print(r'')
-print(r'')
+print(r'')
+print(r'')
 # print(r'')
 print(r'')
-print(r'')
+print(r'')
 print(r'')
 print(r'')
 print(r'')
@@ -80,12 +80,12 @@ def main():
vcpkg.format(r'bin\zlib1.dll')])
 print(r'')
 id = comp(features, id, 12,
-  [r'license.rtf'])
+  [r'share\license.rtf'])
 id = comp(features, id, 12,
   [r'bin\odbcinstall.exe'],
   fid = 'odbcinstall')
 id = comp(features, id, 12,
-  [r'website.html'],
+  [r'share\website.html'],
   name = 'MonetDB Web Site',
   sid = 'website_html',
   vital = 'no')
@@ -109,7 +109,7 @@ def main():
 print(r'')
 print(r'')
 print(r'')
-print(r'')
+print(r'')
 print(r'')
 print(r'  ')
 print(r'NOT Installed OR REINSTALL')
diff --git a/NT/mksqlwxs.py b/NT/mksqlwxs.py
--- a/NT/mksqlwxs.py
+++ b/NT/mksqlwxs.py
@@ -65,8 +65,8 @@ def main():
 print(r'  '.format(sys.argv[1]))
 print(r'')
 print(r'')
-print(r'')
-print(r'')
+print(r'')
+print(r'')
 # print(r'')
 print(r'')
 print(r'  ')
@@ -99,7 +99,7 @@ def main():
 print(r'')
 print(r'')
 print(r'')
-print(r'')
+print(r'')
 print(r'')
 print(r'')
 msvc = r'C:\Program Files (x86)\Microsoft Visual 
Studio\{}\Community\VC\Redist\MSVC'.format(vs)
@@ -195,7 +195,7 @@ def main():
  r'share\doc\MonetDB-SQL\dump-restore.txt'],
   vital = 'no')
 id = comp(features, id, 18,
-  [r'website.html'],
+  [r'share\website.html'],
   name = 'MonetDB Web Site',
   sid = 'website_html',
   vital = 'no')
@@ -203,7 +203,7 @@ def main():
 print(r'  ')
 print(r'')
 id = comp(features, id, 12,
-  [r'license.rtf',
+  [r'share\license.rtf',
r'M5server.bat',
r'msqldump.bat'])
 id = comp(pyapi3, id, 12,
@@ -259,7 +259,7 @@ def main():
 print(r'')
 print(r'')
 print(r'')
-print(r'')
+print(r'')
 print(r'  ')
 print(r'')
 
diff --git a/buildtools/selinux/monetdb.fc b/buildtools/selinux/monetdb.fc
deleted file mode 100644
--- a/buildtools/selinux/monetdb.fc
+++ /dev/null
@@ -1,15 +0,0 @@
-/usr/bin/monetdbd  --  
gen_context(system_u:object_r:monetdbd_exec_t,s0)
-/usr/bin/mserver5  --  
gen_context(system_u:object_r:mser

MonetDB: unlock - Merge with default branch.

2020-08-12 Thread Sjoerd Mullender
Changeset: 8cf74ff465dd for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=8cf74ff465dd
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
geom/monetdb5/geom.c
monetdb5/mal/mal_debugger.c
monetdb5/mal/mal_runtime.c
monetdb5/modules/kernel/batmmath.c
monetdb5/modules/mal/Tests/inspect05.stable.out
monetdb5/modules/mal/Tests/inspect05.stable.out.int128
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql.h
sql/backends/monet5/sql.mal
sql/backends/monet5/sql_statement.c
sql/backends/monet5/sql_statistics.c
sql/backends/monet5/sql_upgrades.c
sql/test/BugTracker-2016/Tests/decimal_vs_integer.Bug-3941.stable.out

sql/test/BugTracker-2016/Tests/decimal_vs_integer.Bug-3941.stable.out.single

sql/test/BugTracker-2019/Tests/duplicates-not-eliminated-long-CASE-stmt.Bug-6697.stable.out

sql/test/BugTracker-2019/Tests/duplicates-not-eliminated-long-CASE-stmt.Bug-6697.stable.out.single
sql/test/emptydb/Tests/check.stable.out
sql/test/emptydb/Tests/check.stable.out.32bit
sql/test/emptydb/Tests/check.stable.out.int128
sql/test/remote/Tests/partition_elim.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
sql/test/sysmon/Tests/sys_queue_expand.stable.out
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 93987 to 300 lines):

diff --git a/ChangeLog.userstats b/ChangeLog.userstats
new file mode 100644
--- /dev/null
+++ b/ChangeLog.userstats
@@ -0,0 +1,19 @@
+# ChangeLog file for userstats
+# This file is updated with Maddlog
+
+* Mon Aug 10 2020 Ying Zhang 
+- Finished a first version of the new monitoring function
+  user_statistics(), which is only intended for the DBAs.
+  For each database user who has logged in during the current mserver5
+  session, it returns 
+  "username": login name of the database user,
+  "querycount": the number of queries this user has executed since his/her
+  first login,
+  "totalticks": the total execution time (in microsecond) of the queries ran
+  by this user,
+  "maxquery": the query with the longest execution time (if two queries have
+  the same execution time, the newer overwrites the older),
+  "maxticks": the execution time of the 'maxquery' (in microsecond),
+  "started": the start timestamp of the 'maxquery',
+  "finished": the finish timestamp of the 'maxquery'.
+
diff --git a/clients/Tests/MAL-signatures.stable.out 
b/clients/Tests/MAL-signatures.stable.out
--- a/clients/Tests/MAL-signatures.stable.out
+++ b/clients/Tests/MAL-signatures.stable.out
@@ -3553,7 +3553,8 @@ stdout of test 'MAL-signatures` in direc
 [ "batcalc",   "bte",  "command batcalc.bte(X_1:int, X_2:bat[:sht], 
X_3:bat[:cnd], X_4:int, X_5:int):bat[:bte] ",  "batsht_dec2dec_cand_bte;",  
   ""  ]
 [ "batcalc",   "bte",  "command batcalc.bte(X_1:bat[:sht], X_2:int, 
X_3:int):bat[:bte] ",  "batsht_num2dec_bte;",  ""  ]
 [ "batcalc",   "bte",  "command batcalc.bte(X_1:bat[:sht], X_2:bat[:cnd], 
X_3:int, X_4:int):bat[:bte] ",   "batsht_num2dec_cand_bte;", ""  ]
-[ "batcalc",   "bte",  "command batcalc.bte(X_1:bat[:str], X_2:int, 
X_3:int):bat[:bte] ",  "batstr_2dec_bte;", ""  ]
+[ "batcalc",   "bte",  "pattern batcalc.bte(X_1:bat[:str], X_2:bat[:cnd], 
X_3:int, X_4:int):bat[:bte] ",   "batstr_2dec_bte;", ""  ]
+[ "batcalc",   "bte",  "pattern batcalc.bte(X_1:bat[:str], X_2:int, 
X_3:int):bat[:bte] ",  "batstr_2dec_bte;", ""  ]
 [ "batcalc",   "bte_noerror",  "pattern 
batcalc.bte_noerror(X_1:bat[:bit]):bat[:bte] ","CMDconvert_bte;",  
""  ]
 [ "batcalc",   "bte_noerror",  "pattern batcalc.bte_noerror(X_1:bat[:bit], 
X_2:bat[:cnd]):bat[:bte] ", "CMDconvert_bte;",  ""  ]
 [ "batcalc",   "bte_noerror",  "pattern 
batcalc.bte_noerror(X_1:bat[:bte]):bat[:bte] ","CMDconvert_bte;",  
""  ]
@@ -3807,15 +3808,22 @@ stdout of test 'MAL-signatures` in direc
 [ "batcalc",   "cmp",  "pattern batcalc.cmp(X_1:str, X_2:bat[:str]):bat[:bte] 
",   "CMDbatCMP;",   ""  ]
 [ "batcalc",   "cmp",  "pattern batcalc.cmp(X_1:str, X_2:bat[:str], 
X_3:bat[:cnd]):bat[:bte] ","CMDbatCMP;",   ""  ]
 [ "batcalc",   "date", "command batcalc.date(X_1:bat[:date]):bat[:date] ", 
"MTIMEdate_date_bulk;", ""  ]
+[ "batcalc",   "date", "command batcalc.date(X_1:bat[:date], 
X_2:bat[:oid]):bat[:date] ",  "MTIMEdate_date_bulk_cand;",""  ]
 [ "batcalc",   "date", "command batcalc.date(X_1:bat[:str]):bat[:date] ",  
"MTIMEdate_fromstr_bulk;",  ""  ]
+[ "batcalc",   "date", "command batcalc.date(X_1:bat[:str], 
X_2:bat[:oid]):bat[:date] ",   "MTIMEd

MonetDB: unlock - Merge with default branch.

2020-08-07 Thread Sjoerd Mullender
Changeset: 6ad61b14fa42 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=6ad61b14fa42
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
gdk/gdk_select.c
monetdb5/modules/mal/pcre.c
sql/backends/monet5/rel_bin.c
sql/common/sql_types.c
sql/test/sys-schema/Tests/systemfunctions.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 6076 to 300 lines):

diff --git a/MonetDB.spec b/MonetDB.spec
--- a/MonetDB.spec
+++ b/MonetDB.spec
@@ -111,7 +111,7 @@ BuildRequires: checkpolicy
 BuildRequires: selinux-policy-devel
 BuildRequires: hardlink
 %endif
-BuildRequires: cmake >= 3.12
+BuildRequires: cmake3 >= 3.12
 BuildRequires: gcc
 BuildRequires: bison
 BuildRequires: /usr/bin/python3
@@ -605,7 +605,7 @@ use SQL with MonetDB, you will need to i
 %config(noreplace) %attr(664,monetdb,monetdb) 
%{_localstatedir}/monetdb5/dbfarm/.merovingian_properties
 %verify(not mtime) %attr(664,monetdb,monetdb) 
%{_localstatedir}/monetdb5/dbfarm/.merovingian_lock
 %config(noreplace) %attr(644,root,root) %{_sysconfdir}/logrotate.d/monetdbd
-%{_libdir}/monetdb5/lib_sql.so*
+%{_libdir}/libmonetdbsql.so*
 %doc %{_mandir}/man1/monetdb.1.gz
 %doc %{_mandir}/man1/monetdbd.1.gz
 %dir %{_datadir}/doc/MonetDB-SQL
@@ -762,7 +762,7 @@ fi
 %setup -q
 
 %build
-%{cmake} \
+%cmake3 \
-DASSERT=OFF \
-DCINTEGRATION=%{?with_cintegration:ON}%{!?with_cintegration:OFF} \
-DFITS=%{?with_fits:ON}%{!?with_fits:OFF} \
@@ -791,7 +791,7 @@ fi
-DWITH_XML2=ON \
-DWITH_ZLIB=ON
 
-%cmake_build
+%cmake3_build
 
 %if %{?rhel:0}%{!?rhel:1} || 0%{?rhel} >= 7
 cd buildtools/selinux
@@ -810,7 +810,7 @@ cd -
 %endif
 
 %install
-%cmake_install
+%cmake3_install
 
 # move file to correct location
 %if %{?rhel:0}%{!?rhel:1} || 0%{?rhel} >= 7
diff --git a/NT/mksqlwxs.py b/NT/mksqlwxs.py
--- a/NT/mksqlwxs.py
+++ b/NT/mksqlwxs.py
@@ -124,9 +124,10 @@ def main():
   [r'bin\mclient.exe',
r'bin\mserver5.exe',
r'bin\msqldump.exe',
-   r'bin\gdk.dll',
+   r'bin\bat.dll',
r'bin\mapi.dll',
r'bin\monetdb5.dll',
+   r'bin\monetdbsql.dll',
r'bin\stream.dll',
vcpkg.format(r'bin\libiconv.dll'),
vcpkg.format(r'bin\bz2.dll'),
@@ -166,18 +167,19 @@ def main():
 id = comp(features, id, 16,
   [r'lib\monetdb5\microbenchmark.mal'])
 id = comp(features, id, 16,
-  [r'lib\monetdb5\{}'.format(x) for x in sorted(filter(lambda x: 
x.startswith('lib_') and x.endswith('.dll') and ('geom' not in x) and ('pyapi' 
not in x) and ('opt_sql_append' not in x), os.listdir(os.path.join(sys.argv[3], 
'lib', 'monetdb5'])
+  [r'lib\monetdb5\{}'.format(x) for x in sorted(filter(lambda x: 
x.startswith('_') and x.endswith('.dll') and ('geom' not in x) and ('pyapi' not 
in x) and ('opt_sql_append' not in x), os.listdir(os.path.join(sys.argv[3], 
'lib', 'monetdb5'])
 id = comp(debug, id, 16,
-  [r'lib\monetdb5\{}'.format(x) for x in sorted(filter(lambda x: 
x.startswith('lib_') and x.endswith('.pdb') and ('geom' not in x) and 
('opt_sql_append' not in x), os.listdir(os.path.join(sys.argv[3], 'lib', 
'monetdb5'])
+  [r'lib\monetdb5\{}'.format(x) for x in sorted(filter(lambda x: 
x.startswith('_') and x.endswith('.pdb') and ('geom' not in x) and 
('opt_sql_append' not in x), os.listdir(os.path.join(sys.argv[3], 'lib', 
'monetdb5'])
 id = comp(geom, id, 16,
-  [r'lib\monetdb5\{}'.format(x) for x in sorted(filter(lambda x: 
x.startswith('lib_') and (x.endswith('.dll') or x.endswith('.pdb')) and ('geom' 
in x), os.listdir(os.path.join(sys.argv[3], 'lib', 'monetdb5'])
+  [r'lib\monetdb5\{}'.format(x) for x in sorted(filter(lambda x: 
x.startswith('_') and (x.endswith('.dll') or x.endswith('.pdb')) and ('geom' in 
x), os.listdir(os.path.join(sys.argv[3], 'lib', 'monetdb5'])
 id = comp(pyapi3, id, 16,
   [r'lib\monetdb5\_pyapi3.dll'])
 print(r'  ')
 id = comp(extend, id, 14,
-  [r'lib\gdk.lib',
+  [r'lib\bat.lib',
r'lib\mapi.lib',
r'lib\monetdb5.lib',
+   r'lib\monetdbsql.lib',
r'lib\stream.lib',
vcpkg.format(r'lib\libiconv.lib'),
vcpkg.format(r'lib\bz2.lib'),
diff --git a/clients/Tests/MAL-signatures.stable.out 
b/clients/Tests/MAL-signatures.stable.out
--- a/clients/Tests/MAL-signatures.stable.out
+++ b/clients/Tests/MAL-signatures.stable.out
@@ -777,14 +777,30 @@ stdout of test 'MAL-signatures` in direc
 [ "bataggr",   "not_exist","pattern bataggr.not_exist(X_1:any_1):bat[:bit] 

MonetDB: unlock - Merge with default branch.

2020-07-30 Thread Sjoerd Mullender
Changeset: 79030cfe1ebb for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=79030cfe1ebb
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
monetdb5/modules/mal/batcalc.c
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 13390 to 300 lines):

diff --git a/clients/Tests/MAL-signatures.stable.out 
b/clients/Tests/MAL-signatures.stable.out
--- a/clients/Tests/MAL-signatures.stable.out
+++ b/clients/Tests/MAL-signatures.stable.out
@@ -787,7637 +787,2609 @@ stdout of test 'MAL-signatures` in direc
 [ "batalgebra","not_like", "command 
batalgebra.not_like(X_1:bat[:str], X_2:str, X_3:str):bat[:bit] ",  
"BATPCREnotlike;",  ""  ]
 [ "batblob",   "nitems",   "command 
batblob.nitems(X_1:bat[:blob]):bat[:int] ","BLOBnitems_bulk;", ""  ]
 [ "batcalc",   "!=",   "pattern batcalc.!=(X_1:any_1, 
X_2:bat[:any_1]):bat[:bit] ","CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:any_1, X_2:bat[:any_1], 
X_3:bat[:bit]):bat[:bit] ", "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:any_1, X_2:bat[:any_1], 
X_3:bat[:bit], X_4:bit):bat[:bit] ","CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:any_1, X_2:bat[:any_1], 
X_3:bat[:msk]):bat[:bit] ", "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:any_1, X_2:bat[:any_1], 
X_3:bat[:msk], X_4:bit):bat[:bit] ","CMDbatNE;",""  ]
 [ "batcalc",   "!=",   "pattern batcalc.!=(X_1:any_1, X_2:bat[:any_1], 
X_3:bat[:oid]):bat[:bit] ", "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:any_1, X_2:bat[:any_1], 
X_3:bat[:oid], X_4:bat[:bit]):bat[:bit] ",  "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:any_1, X_2:bat[:any_1], 
X_3:bat[:oid], X_4:bat[:bit], X_5:bit):bat[:bit] ", "CMDbatNE;",""  
]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:any_1, X_2:bat[:any_1], 
X_3:bat[:oid], X_4:bat[:msk]):bat[:bit] ",  "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:any_1, X_2:bat[:any_1], 
X_3:bat[:oid], X_4:bat[:msk], X_5:bit):bat[:bit] ", "CMDbatNE;",""  
]
 [ "batcalc",   "!=",   "pattern batcalc.!=(X_1:any_1, X_2:bat[:any_1], 
X_3:bat[:oid], X_4:bit):bat[:bit] ","CMDbatNE;",""  ]
 [ "batcalc",   "!=",   "pattern batcalc.!=(X_1:any_1, X_2:bat[:any_1], 
X_3:bit):bat[:bit] ",   "CMDbatNE;",""  ]
 [ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], 
X_2:any_1):bat[:bit] ","CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:any_1, 
X_3:bat[:bit]):bat[:bit] ", "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:any_1, 
X_3:bat[:bit], X_4:bit):bat[:bit] ","CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:any_1, 
X_3:bat[:msk]):bat[:bit] ", "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:any_1, 
X_3:bat[:msk], X_4:bit):bat[:bit] ","CMDbatNE;",""  ]
 [ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:any_1, 
X_3:bat[:oid]):bat[:bit] ", "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:any_1, 
X_3:bat[:oid], X_4:bat[:bit]):bat[:bit] ",  "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:any_1, 
X_3:bat[:oid], X_4:bat[:bit], X_5:bit):bat[:bit] ", "CMDbatNE;",""  
]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:any_1, 
X_3:bat[:oid], X_4:bat[:msk]):bat[:bit] ",  "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:any_1, 
X_3:bat[:oid], X_4:bat[:msk], X_5:bit):bat[:bit] ", "CMDbatNE;",""  
]
 [ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:any_1, 
X_3:bat[:oid], X_4:bit):bat[:bit] ","CMDbatNE;",""  ]
 [ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:any_1, 
X_3:bit):bat[:bit] ",   "CMDbatNE;",""  ]
 [ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], 
X_2:bat[:any_1]):bat[:bit] ",  "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:bat[:any_1], 
X_3:bat[:bit]):bat[:bit] ",   "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:bat[:any_1], 
X_3:bat[:bit], X_4:bit):bat[:bit] ",  "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:bat[:any_1], 
X_3:bat[:msk]):bat[:bit] ",   "CMDbatNE;",""  ]
-[ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:bat[:any_1], 
X_3:bat[:msk], X_4:bit):bat[:bit] ",  "CMDbatNE;",""  ]
 [ "batcalc",   "!=",   "pattern batcalc.!=(X_1:bat[:any_1], X_2:bat[:any_1], 
X_3:bat[:oid], 

MonetDB: unlock - Merge with default branch.

2020-07-30 Thread Sjoerd Mullender
Changeset: cd24a711e891 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=cd24a711e891
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
gdk/gdk_aggr.c
gdk/gdk_calc.c
gdk/gdk_calc_compare.h
gdk/gdk_string.c
monetdb5/modules/kernel/batmmath.c
monetdb5/modules/mal/batcalc.c
monetdb5/optimizer/opt_mergetable.c
monetdb5/optimizer/opt_pipes.c
monetdb5/optimizer/opt_remap.c
monetdb5/optimizer/opt_support.c
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql.h
sql/backends/monet5/sql_statement.c
sql/backends/monet5/sql_statement.h
sql/backends/monet5/sql_upgrades.c
sql/test/BugTracker-2016/Tests/storagemodel.stable.out

sql/test/BugTracker-2019/Tests/duplicates-not-eliminated-long-CASE-stmt.Bug-6697.stable.out

sql/test/BugTracker-2019/Tests/duplicates-not-eliminated-long-CASE-stmt.Bug-6697.stable.out.single
sql/test/emptydb/Tests/check.stable.out
sql/test/emptydb/Tests/check.stable.out.32bit
sql/test/emptydb/Tests/check.stable.out.int128
sql/test/mapi/Tests/sql_int128.stable.out.int128
sql/test/mergetables/Tests/mergequery.stable.out
sql/test/pg_regress/Tests/alter_table.stable.err
sql/test/remote/Tests/partition_elim.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 222450 to 300 lines):

diff --git a/clients/Tests/MAL-signatures.stable.out 
b/clients/Tests/MAL-signatures.stable.out
--- a/clients/Tests/MAL-signatures.stable.out
+++ b/clients/Tests/MAL-signatures.stable.out
@@ -8599,8 +8599,6 @@ stdout of test 'MAL-signatures` in direc
 [ "batcalc",   "bit_noerror",  "pattern batcalc.bit_noerror(X_1:bat[:str], 
X_2:bat[:oid], X_3:bat[:bit]):bat[:bit] ",  "CMDconvert_bit;",  ""  ]
 [ "batcalc",   "bit_noerror",  "pattern batcalc.bit_noerror(X_1:bat[:str], 
X_2:bat[:oid], X_3:bat[:msk]):bat[:bit] ",  "CMDconvert_bit;",  ""  ]
 [ "batcalc",   "blob", "command batcalc.blob(X_1:bat[:str]):bat[:blob] ",  
"batstr_2_blob;",   ""  ]
-[ "batcalc",   "blob", "command batcalc.blob(X_1:bat[:str], 
X_2:bat[:bit]):bat[:blob] ",   "batstr_ce_2_blob;",""  ]
-[ "batcalc",   "blob", "command batcalc.blob(X_1:bat[:str], 
X_2:bat[:msk]):bat[:blob] ",   "batstr_ce_2_blob;",""  ]
 [ "batcalc",   "bte",  "pattern batcalc.bte(X_1:bat[:bit]):bat[:bte] ",
"CMDconvertsignal_bte;",""  ]
 [ "batcalc",   "bte",  "pattern batcalc.bte(X_1:bat[:bit], 
X_2:bat[:bit]):bat[:bte] ", "CMDconvertsignal_bte;",""  ]
 [ "batcalc",   "bte",  "pattern batcalc.bte(X_1:bat[:bit], 
X_2:bat[:msk]):bat[:bte] ", "CMDconvertsignal_bte;",""  ]
@@ -9463,11 +9461,7 @@ stdout of test 'MAL-signatures` in direc
 [ "batcalc",   "date", "command batcalc.date(X_1:bat[:str]):bat[:date] ",  
"MTIMEdate_fromstr_bulk;",  ""  ]
 [ "batcalc",   "date", "command batcalc.date(X_1:bat[:timestamp]):bat[:date] 
","MTIMEtimestamp_extract_date_bulk;",""  ]
 [ "batcalc",   "date", "command batcalc.date(X_1:bat[:str]):bat[:date] ",  
"batstr_2_date;",   ""  ]
-[ "batcalc",   "date", "command batcalc.date(X_1:bat[:str], 
X_2:bat[:bit]):bat[:date] ",   "batstr_ce_2_date;",""  ]
-[ "batcalc",   "date", "command batcalc.date(X_1:bat[:str], 
X_2:bat[:msk]):bat[:date] ",   "batstr_ce_2_date;",""  ]
 [ "batcalc",   "date", "pattern batcalc.date(X_1:bat[:oid]):bat[:date] ",  
"nil_2_date;",  ""  ]
-[ "batcalc",   "date", "pattern batcalc.date(X_1:bat[:oid], 
X_2:bat[:bit]):bat[:date] ",   "nil_2_date;",  ""  ]
-[ "batcalc",   "date", "pattern batcalc.date(X_1:bat[:oid], 
X_2:bat[:msk]):bat[:date] ",   "nil_2_date;",  ""  ]
 [ "batcalc",   "daytime",  "command 
batcalc.daytime(X_1:bat[:daytime]):bat[:daytime] ",
"MTIMEdaytime_daytime_bulk;",   ""  ]
 [ "batcalc",   "daytime",  "command 
batcalc.daytime(X_1:bat[:lng]):bat[:daytime] ",
"MTIMEdaytime_fromseconds_bulk;",   ""  ]
 [ "batcalc",   "daytime",  "command 
batcalc.daytime(X_1:bat[:str]):bat[:daytime] ",
"MTIMEdaytime_fromstr_bulk;",   ""  ]
@@ -9475,8 +9469,6 @@ stdout of test 'MAL-signatures` in direc
 [ "batcalc",   "daytime",  "command batcalc.daytime(X_1:bat[:str], 
X_2:int):bat[:daytime] ",   "batstr_2time_daytime;",""  ]
 [ "batcalc",   "daytime",  "pattern batcalc.daytime(X_1:bat[:daytime], 
X_2:int):bat[:daytime] ",   "daytime_2time_daytime;",   ""  ]
 [ "batcalc",   "daytime",  "pattern batcalc.daytime(X_1:bat[:oid], 
X_2:int):bat[:daytime]

MonetDB: unlock - Merge with default branch.

2020-07-29 Thread Sjoerd Mullender
Changeset: 807b2332eec2 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=807b2332eec2
Modified Files:
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql_statement.c
Branch: unlock
Log Message:

Merge with default branch.


diffs (257 lines):

diff --git a/monetdb5/modules/mal/sysmon.c b/monetdb5/modules/mal/sysmon.c
--- a/monetdb5/modules/mal/sysmon.c
+++ b/monetdb5/modules/mal/sysmon.c
@@ -31,13 +31,14 @@ SYSMONqueue(Client cntxt, MalBlkPtr mb, 
bat *w = getArgReference_bat(stk,pci,7);
bat *m = getArgReference_bat(stk,pci,8);
lng qtag;
-   int wrk, mem, sz;
+   int wrk, mem;
+   BUN sz;
timestamp tsn;
str msg = MAL_SUCCEED;
 
(void) cntxt;
(void) mb;
-   sz = qsize; // reserve space for all tuples in QRYqueue
+   sz = (BUN) qsize;   // reserve space for all tuples in QRYqueue
tag = COLnew(0, TYPE_lng, sz, TRANSIENT);
sessionid = COLnew(0, TYPE_int, sz, TRANSIENT);
user = COLnew(0, TYPE_str, sz, TRANSIENT);
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
@@ -774,7 +774,7 @@ exp_bin(backend *be, sql_exp *e, stmt *l
}
assert(!e->r);
if (exps) {
-   int nrcols = 0;
+   unsigned nrcols = 0;
int push_cond_exec = 0, coalesce = 0;
stmt *ncond = NULL, *ocond = cond;
 
diff --git a/sql/backends/monet5/sql_statement.c 
b/sql/backends/monet5/sql_statement.c
--- a/sql/backends/monet5/sql_statement.c
+++ b/sql/backends/monet5/sql_statement.c
@@ -2612,7 +2612,7 @@ stmt_catalog(backend *be, int type, stmt
 void
 stmt_set_nrcols(stmt *s)
 {
-   int nrcols = 0;
+   unsigned nrcols = 0;
int key = 1;
node *n;
list *l = s->op4.lval;
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
@@ -3167,34 +3167,33 @@ static sql_exp *
 rel_nop(sql_query *query, sql_rel **rel, symbol *se, int fs, exp_kind ek)
 {
mvc *sql = query->sql;
-   int nr_args = 0;
+   int nr_args = 0, err = 0;
dnode *l = se->data.lval->h;
dnode *ops = l->next->next->data.lval?l->next->next->data.lval->h:NULL;
list *exps = sa_list(sql->sa), *tl = sa_list(sql->sa);
sql_subfunc *sf = NULL;
sql_schema *s = cur_schema(sql);
exp_kind iek = {type_value, card_column, FALSE};
-   int err = 0;
 
for (; ops; ops = ops->next, nr_args++) {
-   sql_exp *e = rel_value_exp(query, rel, ops->data.sym, fs, iek);
-   sql_subtype *tpe;
-
-   if (!e)
-   err = 1;
-   append(exps, e);
-   if (e) {
-   tpe = exp_subtype(e);
-   append(tl, tpe);
+   if (!err) { /* we need the nr_args count at the end, but if an 
error is found, stop calling rel_value_exp */
+   sql_exp *e = rel_value_exp(query, rel, ops->data.sym, 
fs, iek);
+   if (!e) {
+   err = 1;
+   continue;
+   }
+   append(exps, e);
+   append(tl, exp_subtype(e));
}
}
if (l->type == type_int) {
/* exec nr (ops)*/
int nr = l->data.i_val;
-   cq *q = qc_find(sql->qc, nr);
-
-   if (q) {
-   node *n, *m;
+   cq *q;
+
+   if (err)
+   return NULL;
+   if ((q = qc_find(sql->qc, nr))) {
list *nexps = new_exp_list(sql->sa);
sql_func *f = q->f;
 
@@ -3202,7 +3201,7 @@ rel_nop(sql_query *query, sql_rel **rel,
if (list_length(f->ops) != list_length(exps))
return sql_error(sql, 02, SQLSTATE(42000) "EXEC 
called with wrong number of arguments: expected %d, got %d", 
list_length(f->ops), list_length(exps));
if (exps->h && f->ops) {
-   for (n = exps->h, m = f->ops->h; n && m; n = 
n->next, m = m->next) {
+   for (node *n = exps->h, *m = f->ops->h; n && m; 
n = n->next, m = m->next) {
sql_arg *a = m->data;
sql_exp *e = n->data;
sql_subtype *ntp = &a->type;
@@ -3219,6 +3218,7 @@ rel_nop(sql_query *query, sql_rel **rel,
sql->type = q->type;
if (nexps)
return exp_op(sql->sa, nexps, 
sql_dup_subfunc(sql->sa, f, tl, NULL));
+   return NULL;
   

MonetDB: unlock - Merge with default branch.

2020-07-28 Thread Sjoerd Mullender
Changeset: 77e0b40bb4d1 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=77e0b40bb4d1
Modified Files:
clients/Tests/exports.stable.out
monetdb5/mal/mal_runtime.c
sql/backends/monet5/UDF/pyapi3/conversion3.c
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql_gencode.c
sql/backends/monet5/sql_statement.c
sql/backends/monet5/sql_upgrades.c
sql/common/sql_types.c
sql/server/rel_optimizer.c
sql/storage/store.c
sql/test/emptydb/Tests/check.stable.out
sql/test/emptydb/Tests/check.stable.out.32bit
sql/test/emptydb/Tests/check.stable.out.int128
sql/test/sys-schema/Tests/systemfunctions.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 5535 to 300 lines):

diff --git a/CMakeLists.txt b/CMakeLists.txt
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -55,7 +55,6 @@ include(monetdb-toolchain)
 monetdb_default_toolchain()
 #monetdb_default_compiler_options()
 
-
 include(monetdb-defines)
 monetdb_hg_revision()
 
@@ -155,6 +154,7 @@ add_subdirectory(tools)
 if(TESTING)
   add_subdirectory(testing)
 endif()
+add_subdirectory(buildtools)
 
 include(CMakePackageConfigHelpers)
 configure_package_config_file(${CMAKE_CURRENT_SOURCE_DIR}/Config.cmake.in
diff --git a/NT/mkodbcwxs.py b/NT/mkodbcwxs.py
--- a/NT/mkodbcwxs.py
+++ b/NT/mkodbcwxs.py
@@ -4,7 +4,7 @@
 #
 # Copyright 1997 - July 2008 CWI, August 2008 - 2020 MonetDB B.V.
 
-# python mkodbcwxs.py VERSION makedefs.txt PREFIX > 
PREFIX/MonetDB-ODBC-Installer.wxs
+# python mkodbcwxs.py VERSION BITS PREFIX > PREFIX/MonetDB-ODBC-Installer.wxs
 # "c:\Program Files (x86)\WiX Toolset v3.10\bin\candle.exe" -nologo -arch 
x64/x86 PREFIX/MonetDB-ODBC-Installer.wxs
 # "c:\Program Files (x86)\WiX Toolset v3.10\bin\light.exe" -nologo -sice:ICE03 
-sice:ICE60 -sice:ICE82 -ext WixUIExtension PREFIX/MonetDB-ODBC-Installer.wixobj
 
@@ -29,21 +29,19 @@ def comp(features, id, depth, files, fid
 
 def main():
 if len(sys.argv) != 4:
-print(r'Usage: mkodbcwxs.py version makedefs.txt installdir')
+print(r'Usage: mkodbcwxs.py version bits installdir')
 return 1
-makedefs = {}
-for line in open(sys.argv[2]):
-key, val = line.strip().split('=', 1)
-makedefs[key] = val
-if makedefs['bits'] == '64':
+if sys.argv[2] == '64':
 folder = r'ProgramFiles64Folder'
 arch = 'x64'
 libcrypto = '-x64'
+vcpkg = r'C:\vcpkg\installed\x64-windows\{}'
 else:
 folder = r'ProgramFilesFolder'
 arch = 'x86'
 libcrypto = ''
-vs = os.getenv('vs')# inherited from TestTools\common.bat
+vcpkg = r'C:\vcpkg\installed\x86-windows\{}'
+vs = '2019'
 features = []
 print(r'')
 print(r'http://schemas.microsoft.com/wix/2006/wi";>')
@@ -59,7 +57,7 @@ def main():
 print(r'')
 print(r'')
 print(r'')
-msvc = r'C:\Program Files (x86)\Microsoft Visual 
Studio\20{}\Community\VC\Redist\MSVC'.format(vs)
+msvc = r'C:\Program Files (x86)\Microsoft Visual 
Studio\{}\Community\VC\Redist\MSVC'.format(vs)
 d = sorted(os.listdir(msvc))[-1]
 msm = '_CRT_{}.msm'.format(arch)
 for f in sorted(os.listdir(os.path.join(msvc, d, 'MergeModules'))):
@@ -72,14 +70,14 @@ def main():
 id = 1
 print(r'')
 id = comp(features, id, 14,
-  [r'lib\libmapi.dll', r'lib\libmapi.pdb',
-   r'lib\libMonetODBC.dll', r'lib\libMonetODBC.pdb',
-   r'lib\libMonetODBCs.dll', r'lib\libMonetODBCs.pdb',
-   r'lib\libstream.dll', r'lib\libstream.pdb',
-   r'{}\bin\iconv-2.dll'.format(makedefs['LIBICONV']),
-   r'{}\bin\libbz2.dll'.format(makedefs['LIBBZIP2']),
-   r'{}\bin\libcrypto-1_1{}.dll'.format(makedefs['LIBOPENSSL'], 
libcrypto),
-   r'{}\bin\zlib1.dll'.format(makedefs['LIBZLIB'])])
+  [r'bin\mapi.dll', # r'lib\mapi.pdb',
+   r'bin\MonetODBC.dll', # r'lib\MonetODBC.pdb',
+   r'bin\MonetODBCs.dll', # r'lib\MonetODBCs.pdb',
+   r'bin\stream.dll', # r'lib\stream.pdb',
+   vcpkg.format(r'bin\libiconv.dll'),
+   vcpkg.format(r'bin\bz2.dll'),
+   vcpkg.format(r'bin\libcrypto-1_1{}.dll'.format(libcrypto)),
+   vcpkg.format(r'bin\zlib1.dll')])
 print(r'')
 id = comp(features, id, 12,
   [r'license.rtf'])
diff --git a/NT/mksqlwxs.py b/NT/mksqlwxs.py
--- a/NT/mksqlwxs.py
+++ b/NT/mksqlwxs.py
@@ -4,7 +4,7 @@
 #
 # Copyright 1997 - July 2008 CWI, August 2008 - 2020 MonetDB B.V.
 
-# python mksqlwxs.py VERSION makedefs.txt PREFIX > 
PREFIX/MonetDB5-SQL-Installer.wxs
+# python mksqlwxs.py VERSION BITS PREFIX > PREFIX/MonetDB5-SQL-Installer.wxs
 # "c:\Program Files (x86)\WiX Toolset v3.10\bin\candle.exe" -nologo 

MonetDB: unlock - Merge with default branch.

2020-06-29 Thread Sjoerd Mullender
Changeset: 4d7900f2faa8 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=4d7900f2faa8
Added Files:
ctest/cmake/test_detect_legacy_var.c.in
ctest/cmake/test_package_detect.c.in
misc/packages/deb/changelog
misc/packages/deb/copyright
misc/packages/rpm/COPYING
misc/packages/rpm/changelog
sql/backends/monet5/sql_time.c
sql/test/astro/Tests/All
sql/test/astro/Tests/drop.sql
sql/test/astro/Tests/drop.stable.err
sql/test/astro/Tests/drop.stable.out
sql/test/astro/Tests/schema.sql
sql/test/astro/Tests/schema.stable.err
sql/test/astro/Tests/schema.stable.out
sql/test/astro/Tests/update.sql
sql/test/astro/Tests/update.stable.err
sql/test/astro/Tests/update.stable.out
sql/test/miscellaneous/Tests/vessels.sql
sql/test/miscellaneous/Tests/vessels.stable.err
sql/test/miscellaneous/Tests/vessels.stable.out
Removed Files:
COPYING
ctest/cmake/test_detect_curl.c.in
ctest/cmake/test_detect_fits.c.in
monetdb_config_win32.h.in
sql/backends/monet5/sql_bat2time.c
Modified Files:
CMakeLists.txt
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
clients/mapiclient/CMakeLists.txt
clients/mapiclient/dump.c
clients/mapilib/CMakeLists.txt
cmake/monetdb-deb-packages.cmake
cmake/monetdb-defines.cmake
cmake/monetdb-functions.cmake
cmake/monetdb-packages.cmake
cmake/monetdb-rpm-packages.cmake
cmake/monetdb-toolchain.cmake
common/options/CMakeLists.txt
common/stream/CMakeLists.txt
common/utils/msabaoth.c
common/utils/msabaoth.h
common/utils/mstring.h
common/utils/mutils.c
common/utils/mutils.h
ctest/cmake/CMakeLists.txt
ctest/cmake/detect-curl.cmake
ctest/cmake/detect-fits.cmake
ctest/cmake/set-cmake-vars.cmake
ctest/cmake/set-dir-vars.cmake
ctest/monetdb5/mal/test_malEmbeddedBoot.c
ctest/tools/monetdbe/example2.c
gdk/CMakeLists.txt
gdk/gdk_string.c
monetdb5/mal/Tests/tst830.stable.out
monetdb5/mal/mal.c
monetdb5/mal/mal_authorize.c
monetdb5/mal/mal_embedded.c
monetdb5/mal/mal_embedded.h
monetdb5/modules/atoms/xml.c
monetdb5/optimizer/opt_postfix.c
monetdb5/tools/CMakeLists.txt
monetdb_config.h.in
sql/CMakeLists.txt
sql/backends/monet5/CMakeLists.txt
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql.h
sql/backends/monet5/sql.mal
sql/backends/monet5/sql_cast.c
sql/backends/monet5/sql_round_impl.h
sql/backends/monet5/vaults/shp/shp.h
sql/include/sql_catalog.h
sql/rel.txt
sql/scripts/58_hot_snapshot.sql
sql/server/rel_dump.c
sql/server/rel_exp.c
sql/server/rel_exp.h
sql/server/rel_optimizer.c
sql/server/rel_psm.c
sql/server/rel_rel.c
sql/server/rel_rel.h
sql/server/rel_schema.c
sql/server/rel_select.c
sql/server/rel_unnest.c
sql/server/sql_parser.y
sql/storage/bat/bat_logger.c
sql/test/BugDay_2005-10-06_2.8/Tests/mixed_type.SF-917372.sql
sql/test/BugDay_2005-10-06_2.8/Tests/mixed_type.SF-917372.stable.err
sql/test/BugDay_2005-10-06_2.8/Tests/mixed_type.SF-917372.stable.out
sql/test/BugTracker-2011/Tests/CASE_nested_functions.Bug-2852.sql
sql/test/BugTracker-2011/Tests/CASE_nested_functions.Bug-2852.stable.out

sql/test/BugTracker-2012/Tests/incorrect_cast_from_double_to_int.Bug-2579.stable.err

sql/test/BugTracker-2012/Tests/incorrect_cast_from_double_to_int.Bug-2579.stable.out
sql/test/BugTracker-2012/Tests/interval_timestamp.Bug-3002.stable.err
sql/test/BugTracker-2015/Tests/crash.Bug-3736.stable.out
sql/test/BugTracker-2015/Tests/window_function_crash.Bug-3861.stable.err
sql/test/BugTracker-2016/Tests/storagemodel.stable.out
sql/test/BugTracker-2017/Tests/one-plus-nil.Bug-6243.sql
sql/test/BugTracker-2017/Tests/one-plus-nil.Bug-6243.stable.out
sql/test/BugTracker/Tests/authorization.SF-1430616.stable.out
sql/test/Dependencies/Tests/Dependencies.stable.out
sql/test/Dependencies/Tests/Dependencies.stable.out.int128
sql/test/SQLancer/Tests/sqlancer02.sql
sql/test/Skyserver/Skyserver_functions.sql
sql/test/Skyserver/Skyserver_functions_v6.sql
sql/test/Users/Tests/dropManyUsers.Bug-3764.stable.out
sql/test/analytics/Tests/analytics17.stable.out
sql/test/emptydb/Tests/check.stable.out
sql/test/emptydb/Tests/check.stable.out.32bit
sql/test/emptydb/Tests/che

MonetDB: unlock - Merge with default branch.

2020-06-23 Thread Sjoerd Mullender
Changeset: 5033b5e5516d for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=5033b5e5516d
Added Files:
.editorconfig
README
documentation/old/HowToRelease.rst
documentation/old/HowToStart.rst
documentation/old/README.rst
documentation/old/windowsbuild.rst
documentation/source/cmake.rst
misc/AUTHORS
misc/CMakeLists.txt
misc/ChangeLog
misc/ChangeLog-Archive
misc/ChangeLog.Jun2020
misc/NEWS
misc/python/CMakeLists.txt
misc/python/create_include_object.py.in
misc/python/fixlicense.py
Removed Files:
HowToStart.rst
README.rst
buildtools/AUTHORS
buildtools/ChangeLog
buildtools/ChangeLog-Archive
buildtools/ChangeLog.Jun2020
buildtools/NEWS
buildtools/conf/fixlicense.py
buildtools/doc/HowToRelease.rst
buildtools/doc/Makefile
buildtools/doc/windowsbuild.rst
create_include_object.py.in
Modified Files:
CMakeLists.txt
cmake/Modules/FindSphinx.cmake
cmake/monetdb-functions.cmake
documentation/index.rst
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 359 to 300 lines):

diff --git a/.editorconfig b/.editorconfig
new file mode 100644
--- /dev/null
+++ b/.editorconfig
@@ -0,0 +1,21 @@
+# Unix-style newlines with a newline ending every file
+[*]
+end_of_line = lf
+insert_final_newline = true
+
+[*.{c,h}]
+indent_style = tab
+tab_width = 4
+indent_size = tab
+trim_trailing_whitespace = true
+charset = utf-8
+max_line_length = 120
+
+[*.py]
+indent_style = space
+indent_size = 4
+trim_trailing_whitespace = true
+charset = utf-8
+
+[gdk/*.{c,h}]
+tab_width = 8
diff --git a/CMakeLists.txt b/CMakeLists.txt
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -140,11 +140,6 @@ install(FILES
   DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/monetdb
   COMPONENT monetdbdev)
 
-# [TODO]: install created python file
-configure_file(create_include_object.py.in
-  ${CMAKE_CURRENT_BINARY_DIR}/create_include_object.py
-  @ONLY)
-
 if(${CMAKE_SYSTEM_NAME} STREQUAL "Darwin")
   set(CMAKE_MODULE_LINKER_FLAGS "-Wl,-undefined,dynamic_lookup 
-Wl,-undefined,dynamic_lookup")
 endif()
@@ -152,6 +147,7 @@ endif()
 add_subdirectory(common)
 add_subdirectory(clients)
 add_subdirectory(gdk)
+add_subdirectory(misc)
 add_subdirectory(monetdb5)
 add_subdirectory(sql)
 add_subdirectory(geom)
diff --git a/README b/README
new file mode 100644
--- /dev/null
+++ b/README
@@ -0,0 +1,22 @@
+The MonetDB Database System
+
+The MonetDB database is developed by the CWI database research group
+(see https://www.monetdb.org/).
+
+Via the MonetDB project we have brought the MonetDB system in open source,
+where it is accessible at https://www.monetdb.org/Downloads/
+
+The MonetDB database system is a high-performance database kernel for
+query-intensive applications. The MonetDB source can be found at our mercurial 
server (https://dev.monetdb.org/hg/MonetDB/). There is also a github clone 
(https://github.com/MonetDB/MonetDB) that is updated once a day.
+
+If you got a source distribution, please compile and install MonetDB first,
+following the instructions in the "documentation" directory.
+
+
+Copyright Notice
+
+This Source Code Form is subject to the terms of the Mozilla Public
+License, v. 2.0.  If a copy of the MPL was not distributed with this
+file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+Copyright 1997 - July 2008 CWI, August 2008 - 2020 MonetDB B.V.
diff --git a/buildtools/doc/Makefile b/buildtools/doc/Makefile
deleted file mode 100644
--- a/buildtools/doc/Makefile
+++ /dev/null
@@ -1,13 +0,0 @@
-all: HowToRelease.html windowsbuild.html HowToRelease.pdf windowsbuild.pdf
-
-HowToRelease.html: HowToRelease.rst
-   rst2html HowToRelease.rst > HowToRelease.html
-
-windowsbuild.html: windowsbuild.rst
-   rst2html windowsbuild.rst > windowsbuild.html
-
-HowToRelease.pdf: HowToRelease.rst
-   rst2pdf HowToRelease.rst
-
-windowsbuild.pdf: windowsbuild.rst
-   rst2pdf windowsbuild.rst
diff --git a/cmake/Modules/FindSphinx.cmake b/cmake/Modules/FindSphinx.cmake
--- a/cmake/Modules/FindSphinx.cmake
+++ b/cmake/Modules/FindSphinx.cmake
@@ -1,14 +1,22 @@
+#[[
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0.  If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+# Copyright 1997 - July 2008 CWI, August 2008 - 2020 MonetDB B.V.
+#]]
+
 find_program(SPHINX_EXECUTABLE NAMES sphinx-build
-HINTS
-$ENV{SPHINX_DIR}
-PATH_SUFFIXES bin
-DOC "Sphinx documentation generator"
+  HINTS
+  $ENV{SPHINX_DIR}
+  PATH_SUFFIXES bin
+  DOC "Sphinx documentation generator"
 )
  
 include(FindPackageHandleStandardArgs)
  
 find_package_handle_standard_args(Sphinx DEFAULT_MSG
-SPHINX_EXECUTABLE
+  SPHINX_EXECUTABLE
 )
  
 mark_as_advanced(SPHINX_EXECUTABLE

MonetDB: unlock - Merge with default branch.

2020-06-23 Thread Sjoerd Mullender
Changeset: fccb763b99e9 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=fccb763b99e9
Added Files:
cmake/Modules/FindSphinx.cmake
documentation/CMakeLists.txt
documentation/conf.py.in
documentation/index.rst
documentation/monetdbe/architecture.png
documentation/source/build-debian.rst
documentation/source/build-fedora.rst
documentation/source/build.rst
documentation/source/design.rst
documentation/source/release.rst
gdk/gdk_subquery.c
gdk/gdk_subquery.h
sql/test/json/Tests/jsonkeyarray.Bug-6858.stable.err
sql/test/json/Tests/jsonkeyarray.Bug-6858.stable.out
sql/test/miscellaneous/Tests/simple_plans.stable.out.single
tools/monetdbe/monetdbe_mapi.h
Removed Files:
NT/Makefile
NT/makelibdef.py
NT/monetdb_config.h.in
NT/rules.msc
NT/wincompile.py
NT/winconfig.py
README-Debian
README-Fedora
README.md
Release.md
buildtools/autogen/autogen.py
buildtools/autogen/autogen/__init__.py
buildtools/autogen/autogen/am.py
buildtools/autogen/autogen/codegen.py
buildtools/autogen/autogen/filesplit.py
buildtools/autogen/autogen/msc.py
buildtools/autogen/autogen/var.py
buildtools/conf/config.rpath
buildtools/conf/rules.mk
ctest/tools/embedded/CMakeLists.txt
ctest/tools/embedded/backup.c
ctest/tools/embedded/example1.c
ctest/tools/embedded/example2.c
ctest/tools/embedded/example_append.c
ctest/tools/embedded/example_blob.c
ctest/tools/embedded/example_connections.c
ctest/tools/embedded/example_decimals.c
ctest/tools/embedded/example_temporal.c
ctest/tools/embedded/mapi.c
ctest/tools/embedded/mapi.h
documentation/monetdbe/index.rst
documentation/source/index.rst
monetdb5/extras/mal_optimizer_template/opt_sql_append.h
monetdb5/modules/atoms/json.h
monetdb5/modules/atoms/url.h
monetdb5/modules/kernel/batcolor.h
monetdb5/modules/mal/json_util.h
sql/scripts/10_math.sql
tools/embedded/CMakeLists.txt
tools/embedded/monetdb_embedded.c
tools/embedded/monetdb_embedded.h
tools/monetdbe/mapi.h
Modified Files:
CMakeLists.txt
Config.cmake.in
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
clients/mapiclient/mclient.c
clients/mapilib/CMakeLists.txt
clients/odbc/winsetup/CMakeLists.txt
cmake/monetdb-custom-targets.cmake
cmake/monetdb-defines.cmake
cmake/monetdb-findpackages.cmake
cmake/monetdb-functions.cmake
cmake/monetdb-options.cmake
common/options/CMakeLists.txt
common/stream/CMakeLists.txt
common/stream/stream.c
common/utils/CMakeLists.txt
ctest/tools/monetdbe/cmocka_test.c
ctest/tools/monetdbe/example1.c
ctest/tools/monetdbe/example2.c
ctest/tools/monetdbe/example_append.c
ctest/tools/monetdbe/example_backup.c
ctest/tools/monetdbe/example_blob.c
ctest/tools/monetdbe/example_connections.c
ctest/tools/monetdbe/example_decimals.c
ctest/tools/monetdbe/example_remote.c
ctest/tools/monetdbe/example_temporal.c
ctest/tools/monetdbe/test_helper.c
ctest/tools/monetdbe/test_helper.h
ctest/tools/monetdbe/test_helper_template.h
documentation/monetdbe/introduction.rst
documentation/monetdbe/monetdbe_api.rst
documentation/source/manual_pages/monetdbd.rst.in
gdk/CMakeLists.txt
gdk/gdk_bbp.c
gdk/gdk_bbp.h
gdk/gdk_hash.c
gdk/gdk_tracer.c
gdk/gdk_tracer.h
geom/monetdb5/geom.c
geom/monetdb5/geom.h
monetdb5/extras/mal_optimizer_template/CMakeLists.txt
monetdb5/extras/mal_optimizer_template/opt_sql_append.c
monetdb5/extras/rapi/rapi.c
monetdb5/extras/rapi/rapi.h
monetdb5/mal/mal_prelude.c
monetdb5/mal/mal_profiler.c
monetdb5/mal/mal_runtime.c
monetdb5/mal/mel.h
monetdb5/modules/atoms/CMakeLists.txt
monetdb5/modules/atoms/batxml.c
monetdb5/modules/atoms/blob.c
monetdb5/modules/atoms/blob.h
monetdb5/modules/atoms/color.c
monetdb5/modules/atoms/color.h
monetdb5/modules/atoms/identifier.c
monetdb5/modules/atoms/inet.c
monetdb5/modules/atoms/json.c
monetdb5/modules/atoms/mtime.c
monetdb5/modules/atoms/streams.c
monetdb5/modules/atoms/streams.h
monetdb5/modules/atoms/url.c
monetdb5/modules/atoms/uuid.c
monetdb5/modules/atoms/xml.c
monetdb5/modules/atoms/xml.h
monetdb5/modules/kernel/CMakeLists.txt
  

MonetDB: unlock - Merge with default branch.

2020-06-16 Thread Sjoerd Mullender
Changeset: 067ae147417e for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=067ae147417e
Added Files:
ctest/tools/monetdbe/cmocka_test.c
ctest/tools/monetdbe/example_backup.c
ctest/tools/monetdbe/example_remote.c
ctest/tools/monetdbe/test_helper.c
ctest/tools/monetdbe/test_helper.h
ctest/tools/monetdbe/test_helper_template.h
documentation/monetdbe/authors.rst
documentation/monetdbe/conf.py
documentation/monetdbe/dev_notes.rst
documentation/monetdbe/examples.rst
documentation/monetdbe/index.rst
documentation/monetdbe/installation.rst
documentation/monetdbe/introduction.rst
documentation/monetdbe/monetdbe_api.rst
sql/test/BugTracker-2020/Tests/url-getuser.Bug-6844.sql
sql/test/BugTracker-2020/Tests/url-getuser.Bug-6844.stable.err
sql/test/BugTracker-2020/Tests/url-getuser.Bug-6844.stable.out
sql/test/BugTracker-2020/Tests/url-nulls.Bug-6845.sql
sql/test/BugTracker-2020/Tests/url-nulls.Bug-6845.stable.err
sql/test/BugTracker-2020/Tests/url-nulls.Bug-6845.stable.out
sql/test/json/Tests/jsonkeyarray.Bug-6858.sql
sql/test/json/Tests/jsontext.Bug-6859.sql
tools/monetdbe/mapi.h
tools/monetdbe/monetdbe_mapi.c
Removed Files:
ctest/tools/monetdbe/mapi.c
ctest/tools/monetdbe/mapi.h
documentation/embedded/authors.rst
documentation/embedded/conf.py
documentation/embedded/dev_notes.rst
documentation/embedded/examples.rst
documentation/embedded/index.rst
documentation/embedded/installation.rst
documentation/embedded/introduction.rst
documentation/embedded/monetdbe_api.rst
Modified Files:
CMakeLists.txt
Config.cmake.in
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
cmake/monetdb-defines.cmake
cmake/monetdb-findpackages.cmake
cmake/monetdb-functions.cmake
cmake/monetdb-options.cmake
cmake/monetdb-toolchain.cmake
ctest/tools/monetdbe/CMakeLists.txt
ctest/tools/monetdbe/backup.c
ctest/tools/monetdbe/example1.c
ctest/tools/monetdbe/example2.c
ctest/tools/monetdbe/example_append.c
ctest/tools/monetdbe/example_blob.c
ctest/tools/monetdbe/example_connections.c
ctest/tools/monetdbe/example_decimals.c
ctest/tools/monetdbe/example_temporal.c
documentation/source/manual_pages/mserver5.rst.in
monetdb5/mal/mal.c
monetdb5/mal/mal_embedded.c
monetdb5/mal/mal_profiler.c
monetdb5/mal/mal_session.c
monetdb5/modules/atoms/json.c
monetdb5/modules/atoms/json.h
monetdb5/modules/atoms/json.mal
monetdb5/modules/atoms/url.c
monetdb5/modules/atoms/url.h
monetdb5/modules/atoms/url.mal
monetdb5/modules/mal/pcre.c
monetdb_config.h.in
sql/ChangeLog
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql_gencode.c
sql/backends/monet5/sql_round_impl.h
sql/backends/monet5/sql_scenario.c
sql/backends/monet5/sql_statement.c
sql/backends/monet5/sql_upgrades.c
sql/common/sql_types.c
sql/scripts/12_url.sql
sql/scripts/40_json.sql
sql/server/rel_optimizer.c
sql/server/rel_select.c
sql/server/sql_atom.c
sql/server/sql_atom.h
sql/server/sql_parser.y
sql/server/sql_semantic.c

sql/test/BugDay_2005-10-06_2.9.3/Tests/UNION_JOIN_vs_plain_set_UNION-2.SF-920585.stable.out
sql/test/BugTracker-2012/Tests/url_script_test.Bug-2972.stable.err
sql/test/BugTracker-2012/Tests/url_script_test.Bug-2972.stable.out
sql/test/BugTracker-2015/Tests/All
sql/test/BugTracker-2020/Tests/All
sql/test/SQLancer/Tests/SingleServer
sql/test/SQLancer/Tests/sqlancer01.sql
sql/test/SQLancer/Tests/sqlancer01.stable.err
sql/test/SQLancer/Tests/sqlancer01.stable.out
sql/test/analytics/Tests/analytics07.stable.err
sql/test/analytics/Tests/analytics07.stable.out
sql/test/emptydb/Tests/check.stable.out
sql/test/emptydb/Tests/check.stable.out.32bit
sql/test/emptydb/Tests/check.stable.out.int128
sql/test/json/Tests/All
sql/test/pg_regress/Tests/strings.stable.out
sql/test/pg_regress/Tests/strings_cast.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
tools/merovingian/daemon/config/.merovingian_properties.in
tools/merovingian/daemon/config/monetdbd.in
tools/merovingian/daemon/config/monetdbd.service.in
tools/monetdbe/CMakeLists.txt
tools/monetdbe/monetdbe.c
tools/monetdbe/monetdbe.h
tools/mserve

MonetDB: unlock - Merge with default branch.

2020-06-15 Thread Sjoerd Mullender
Changeset: a91675a2eb8d for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=a91675a2eb8d
Added Files:
ctest/tools/monetdbe/CMakeLists.txt
ctest/tools/monetdbe/backup.c
ctest/tools/monetdbe/example1.c
ctest/tools/monetdbe/example2.c
ctest/tools/monetdbe/example_append.c
ctest/tools/monetdbe/example_blob.c
ctest/tools/monetdbe/example_connections.c
ctest/tools/monetdbe/example_decimals.c
ctest/tools/monetdbe/example_temporal.c
ctest/tools/monetdbe/mapi.c
ctest/tools/monetdbe/mapi.h
documentation/embedded/authors.rst
documentation/embedded/conf.py
documentation/embedded/dev_notes.rst
documentation/embedded/examples.rst
documentation/embedded/index.rst
documentation/embedded/installation.rst
documentation/embedded/introduction.rst
documentation/embedded/monetdbe_api.rst
sql/test/SQLancer/Tests/SingleServer
tools/monetdbe/CMakeLists.txt
tools/monetdbe/monetdbe.c
tools/monetdbe/monetdbe.h
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
clients/mapilib/monetdb-mapi.pc.in
cmake/Modules/FindLZ4.cmake
cmake/monetdb-findpackages.cmake
common/options/CMakeLists.txt
common/stream/CMakeLists.txt
common/stream/monetdb-stream.pc.in
ctest/cmake/detect-iconv.cmake
ctest/tools/CMakeLists.txt
ctest/tools/embedded/backup.c
ctest/tools/embedded/example1.c
ctest/tools/embedded/example2.c
ctest/tools/embedded/example_append.c
ctest/tools/embedded/example_blob.c
ctest/tools/embedded/example_connections.c
ctest/tools/embedded/example_decimals.c
ctest/tools/embedded/example_temporal.c
ctest/tools/embedded/mapi.c
ctest/tools/embedded/mapi.h
gdk/gdk_cross.c
gdk/gdk_join.c
gdk/gdk_select.c
gdk/gdk_utils.c
gdk/monetdb-gdk.pc.in
geom/lib/CMakeLists.txt
geom/monetdb5/CMakeLists.txt
monetdb5/mal/CMakeLists.txt
monetdb5/modules/atoms/str.c
monetdb5/modules/kernel/algebra.c
monetdb5/modules/kernel/algebra.h
monetdb5/modules/kernel/algebra.mal
monetdb5/modules/mal/mal_io.c
monetdb5/modules/mal/pcre.c
monetdb5/modules/mal/pcre.mal
monetdb5/modules/mal/tablet.c
monetdb5/optimizer/opt_mergetable.c
monetdb5/optimizer/opt_postfix.c
monetdb5/optimizer/opt_prelude.c
monetdb5/optimizer/opt_prelude.h
monetdb5/optimizer/opt_profiler.c
monetdb5/optimizer/opt_support.c
monetdb5/tools/CMakeLists.txt
monetdb5/tools/monetdb5.pc.in
sql/backends/monet5/CMakeLists.txt
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql_result.c
sql/backends/monet5/sql_statement.c
sql/server/rel_optimizer.c
sql/server/rel_rewriter.c
sql/server/rel_select.c
sql/server/rel_unnest.c
sql/server/sql_parser.y
sql/test/BugTracker-2017/Tests/date-arithmetic.Bug-6415.sql
sql/test/SQLancer/Tests/sqlancer01.sql
sql/test/SQLancer/Tests/sqlancer01.stable.out
sql/test/emptydb-upgrade-chain/Tests/upgrade.stable.out.int128
sql/test/emptydb-upgrade-chain/Tests/upgrade.stable.out.ppc64
sql/test/emptydb-upgrade/Tests/upgrade.stable.out.int128
sql/test/subquery/Tests/subquery6.sql
sql/test/subquery/Tests/subquery6.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out
sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
sql/test/testdb-upgrade-chain/Tests/upgrade.stable.out.int128
sql/test/testdb-upgrade/Tests/upgrade.stable.out.int128
testing/Mtest.py.in
tools/CMakeLists.txt
tools/embedded/monetdb_embedded.c
tools/embedded/monetdb_embedded.h
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 90418 to 300 lines):

diff --git a/clients/Tests/MAL-signatures.stable.out 
b/clients/Tests/MAL-signatures.stable.out
--- a/clients/Tests/MAL-signatures.stable.out
+++ b/clients/Tests/MAL-signatures.stable.out
@@ -64,10969 +64,6816 @@ stdout of test 'MAL-signatures` in direc
 % .%1, .%1,.%1,.%1,.%1 # table_name
 % module,  function,   signature,  address,comment # name
 % clob,clob,   clob,   clob,   clob # type
-% 12,  28, 364,42, 874 # length
-[ "aggr",  "allnotequal",  "command aggr.allnotequal(l:bat[:any_1], 
r:bat[:any_1]):bit ",  "SQLallnotequal;",  "if all values in r are not 
equal to l return true, else if r has nil nil else false"   ]
-[ "aggr",  "anyequal", "pattern aggr.anyequal(l:any_1, r:any_1):bit ", 
"CMDvarEQ;",""  ]
-[ "aggr",  "any

MonetDB: unlock - Merge with default branch.

2020-06-10 Thread Sjoerd Mullender
Changeset: e8662d079f93 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=e8662d079f93
Added Files:
sql/test/BugTracker-2020/Tests/select-and.Bug-6878.sql
sql/test/BugTracker-2020/Tests/select-and.Bug-6878.stable.err
sql/test/BugTracker-2020/Tests/select-and.Bug-6878.stable.out
sql/test/Tests/like_tests.sql
Removed Files:
sql/test/Tests/like_tests.SQL.py
sql/test/like_tests.sql
Modified Files:
MonetDB.spec
NT/mksqlwxs.py
cmake/monetdb-defines.cmake
cmake/monetdb-options.cmake
ctest/tools/embedded/CMakeLists.txt
debian/libmonetdb-dev.install
gdk/ChangeLog.Jun2020
gdk/gdk_hash.c
gdk/gdk_logger.c
gdk/gdk_select.c
monetdb5/mal/mal_debugger.c
monetdb5/modules/mal/pcre.c
sql/backends/monet5/sql_execute.c
sql/test/BugTracker-2020/Tests/All
sql/test/Tests/hot_snapshot.py
sql/test/emptydb-upgrade-chain/Tests/upgrade.stable.out.powerpc64
sql/test/miscellaneous/Tests/simple_selects.sql
sql/test/miscellaneous/Tests/simple_selects.stable.out
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 672 to 300 lines):

diff --git a/MonetDB.spec b/MonetDB.spec
--- a/MonetDB.spec
+++ b/MonetDB.spec
@@ -201,6 +201,7 @@ functionality of MonetDB.
 %dir %{_includedir}/monetdb
 %{_includedir}/monetdb/gdk*.h
 %{_includedir}/monetdb/matomic.h
+%{_includedir}/monetdb/mstring.h
 %{_includedir}/monetdb/monet*.h
 %{_libdir}/libbat.so
 %{_libdir}/pkgconfig/monetdb-gdk.pc
diff --git a/NT/mksqlwxs.py b/NT/mksqlwxs.py
--- a/NT/mksqlwxs.py
+++ b/NT/mksqlwxs.py
@@ -158,6 +158,7 @@ def main():
   sorted([r'include\monetdb\{}'.format(x) for x in filter(lambda 
x: (x.startswith('gdk') or x.startswith('monet') or x.startswith('mal')) and 
x.endswith('.h'), os.listdir(os.path.join(sys.argv[3], 'include', 'monetdb')))] 
+
  [r'include\monetdb\mapi.h',
   r'include\monetdb\matomic.h',
+  r'include\monetdb\mstring.h',
   r'include\monetdb\stream.h',
   r'include\monetdb\stream_socket.h']),
   vital = 'no')
diff --git a/cmake/monetdb-defines.cmake b/cmake/monetdb-defines.cmake
--- a/cmake/monetdb-defines.cmake
+++ b/cmake/monetdb-defines.cmake
@@ -113,13 +113,8 @@ function(monetdb_configure_defines)
   check_function_exists("uname" HAVE_UNAME)
   # Some libc versions on Linux distributions don't have it
   check_symbol_exists("semtimedop" "sys/types.h;sys/ipc.h;sys/sem.h" 
HAVE_SEMTIMEDOP)
-  cmake_push_check_state()
-if (NOT APPLE)
-  set(CMAKE_REQUIRED_LIBRARIES "${CMAKE_REQUIRED_LIBRARIES};pthread")
-endif()
-check_symbol_exists("pthread_kill" "pthread.h;signal.h" HAVE_PTHREAD_KILL)
-check_symbol_exists("pthread_sigmask" "pthread.h;signal.h" 
HAVE_PTHREAD_SIGMASK)
-  cmake_pop_check_state()
+  check_function_exists("pthread_kill" HAVE_PTHREAD_KILL)
+  check_function_exists("pthread_sigmask" HAVE_PTHREAD_SIGMASK)
   check_symbol_exists("regcomp" "regex.h" HAVE_POSIX_REGEX)
 endfunction()
 
diff --git a/cmake/monetdb-options.cmake b/cmake/monetdb-options.cmake
--- a/cmake/monetdb-options.cmake
+++ b/cmake/monetdb-options.cmake
@@ -74,13 +74,13 @@ option(SANITIZER
   OFF)
 
 cmake_dependent_option(STRICT 
-  "Enable strict compiler flags (default=ON for development sources, OFF for 
tarball instalation)"
+  "Enable strict compiler flags (default=ON for development sources, OFF for 
tarball installation)"
   ON
   "DEVELOPMENT"
   OFF)
 
 cmake_dependent_option(ASSERT 
-  "Enable asserts (default=ON for development sources, OFF for tarball 
instalation)"
+  "Enable asserts (default=ON for development sources, OFF for tarball 
installation)"
   ON
   "DEVELOPMENT"
   OFF)
diff --git a/ctest/tools/embedded/CMakeLists.txt 
b/ctest/tools/embedded/CMakeLists.txt
--- a/ctest/tools/embedded/CMakeLists.txt
+++ b/ctest/tools/embedded/CMakeLists.txt
@@ -10,72 +10,42 @@ add_executable(example1 example1.c)
 target_link_libraries(example1
   PRIVATE
 monetdb_config_header
-embedded
-sqlinclude
-gdk
-mapi
-#sql
-)
+embedded)
 add_test(run_example1 example1)
 
 add_executable(example2 example2.c)
 target_link_libraries(example2
   PRIVATE
 monetdb_config_header
-embedded
-sqlinclude
-gdk
-mapi
-#sql
-)
+embedded)
 add_test(run_example2 example2)
 
 add_executable(example_temporal example_temporal.c)
 target_link_libraries(example_temporal
   PRIVATE
 monetdb_config_header
-embedded
-sqlinclude
-gdk
-mapi
-#sql
-)
+embedded)
 add_test(run_example_temporal example_temporal)
 
 add_executable(example_decimals example_decimals.c)
 target_link_libraries(example_decimals
   PRIVATE
 monetdb_config_header
-embedded
-sqlinclude
-gdk
-mapi
-#sql
-)
+embedded)
 add_test(run_e

MonetDB: unlock - Merge with default branch.

2020-03-31 Thread Sjoerd Mullender
Changeset: 156a05075fcf for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=156a05075fcf
Added Files:
sql/test/merge-partitions/Tests/mergepart30.sql
sql/test/merge-partitions/Tests/mergepart30.stable.err
sql/test/merge-partitions/Tests/mergepart30.stable.out
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
clients/mapiclient/dump.c
clients/mapiclient/mclient.c
clients/odbc/winsetup/setup.c
common/options/getopt.c
common/options/getopt1.c
common/stream/stream.c
common/utils/muuid.c
gdk/ChangeLog.Jun2020
gdk/gdk.h
gdk/gdk_aggr.c
gdk/gdk_analytic_func.c
gdk/gdk_batop.c
gdk/gdk_delta.h
gdk/gdk_posix.c
gdk/gdk_posix.h
gdk/gdk_private.h
gdk/gdk_project.c
gdk/gdk_tracer.c
gdk/gdk_tracer.h
gdk/gdk_utils.h
monetdb5/mal/mal_function.c
monetdb5/mal/mal_function.h
monetdb5/mal/mal_listing.c
monetdb5/mal/mal_listing.h
monetdb5/modules/kernel/algebra.c
monetdb5/modules/kernel/algebra.h
monetdb5/modules/kernel/algebra.mal
monetdb5/modules/mal/mal_io.c
monetdb5/modules/mal/mal_mapi.c
monetdb5/modules/mal/wlc.mal
monetdb5/optimizer/opt_mergetable.c
monetdb5/optimizer/opt_pushselect.c
monetdb5/optimizer/opt_remap.c
monetdb5/tools/Tests/mserver5-ipv6.py
sql/ChangeLog.Jun2020
sql/backends/monet5/Tests/dbextra_lock_test.py
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql_cat.c
sql/backends/monet5/sql_execute.c
sql/backends/monet5/sql_gencode.c
sql/backends/monet5/sql_statement.c
sql/backends/monet5/sql_statement.h
sql/backends/monet5/sqlcatalog.mal
sql/backends/monet5/wlr.mal
sql/include/sql_catalog.h
sql/server/rel_optimizer.c
sql/server/rel_propagate.c
sql/server/rel_propagate.h
sql/server/rel_psm.c
sql/server/rel_schema.c
sql/server/rel_select.c
sql/server/rel_updates.c
sql/server/rel_xml.c
sql/server/sql_mvc.c
sql/server/sql_partition.c
sql/server/sql_privileges.c
sql/server/sql_semantic.c
sql/storage/bat/bat_storage.c
sql/storage/sql_catalog.c
sql/storage/sql_storage.h
sql/storage/store.c

sql/test/BugDay_2005-11-09_2.9.3/Tests/grant_public.SF-1114580.stable.err
sql/test/BugTracker-2009/Tests/create_on_ro_db_crash.SF-2830238.SQL.py
sql/test/BugTracker-2009/Tests/lost_update.SF-2790020.SQL.py

sql/test/BugTracker-2009/Tests/use_order_column_first.SF-2686008.stable.out
sql/test/BugTracker-2010/Tests/new-readonly-db.Bug-2695.SQL.py

sql/test/BugTracker-2011/Tests/interrupted-initialization.Bug-2875.SQL.py

sql/test/BugTracker-2012/Tests/rewrite_like_into_likesubselect.Bug-3179.stable.out
sql/test/BugTracker-2013/Tests/corrupt-after-restart.Bug-3282.SQL.py
sql/test/BugTracker-2014/Tests/acidity-fail.Bug-3635.py
sql/test/BugTracker-2014/Tests/manifold.Bug-3556.stable.out
sql/test/BugTracker-2015/Tests/schemadiff.Bug-3778.SQL.py
sql/test/BugTracker-2017/Tests/shutdown.Bug-6182.SQL.py

sql/test/BugTracker-2017/Tests/wrong_aggregation_count.Bug-6257.stable.out

sql/test/BugTracker-2018/Tests/grant-role-not-idempotent.Bug-6660.stable.err

sql/test/BugTracker-2018/Tests/grant-role-not-idempotent.Bug-6660.stable.out

sql/test/BugTracker-2018/Tests/local_replica_table_not_detected.Bug-6620.py
sql/test/BugTracker-2018/Tests/remote-table-where-is-null.Bug-6601.py
sql/test/BugTracker-2018/Tests/remote-table-where-not-equal.Bug-6621.py
sql/test/BugTracker-2019/Tests/alter_table_drop_column.Bug-6749.py

sql/test/BugTracker-2019/Tests/remote-table-non-existent-column.Bug-6750.py
sql/test/BugTracker-2020/Tests/functions-not-persist.Bug-6819.SQL.py
sql/test/BugTracker/Tests/coalesce_equal_coalesce.SF-1907905.stable.err
sql/test/BugTracker/Tests/explain.SF-1739353.stable.out
sql/test/BugTracker/Tests/jdbc_no_debug.SF-1739356.stable.out
sql/test/BugTracker/Tests/mdb_starts_with_sql_debug_64.SF-1999354.SQL.py
sql/test/BugTracker/Tests/revoke_role.SF-1691646.stable.err
sql/test/BugTracker/Tests/set_a_new_user_password.SF-1844050.SQL.py

sql/test/BugTracker/Tests/set_sql_debug_64__breaking_the_DB.SF-1906287.SQL.py
sql/test/Tests/create_in_schema.stable.err
sql/test/Tests/create_in_schema.stable.out
sql/test/Users/Tests/grantPrivilegesNonDefaultRole.Bug-3365.stable.err
sql/test/group-concat/Tests/groupconcat05.sql
sql/t

MonetDB: unlock - Merge with default branch.

2020-03-30 Thread Sjoerd Mullender
Changeset: caa5942771c3 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=caa5942771c3
Branch: unlock
Log Message:

Merge with default branch.

___
checkin-list mailing list
checkin-list@monetdb.org
https://www.monetdb.org/mailman/listinfo/checkin-list


MonetDB: unlock - Merge with default branch.

2020-03-25 Thread Sjoerd Mullender
Changeset: b578cca12939 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=b578cca12939
Added Files:
sql/test/miscellaneous/Tests/table_udf_missing_var.py
sql/test/miscellaneous/Tests/table_udf_missing_var.stable.err
sql/test/miscellaneous/Tests/table_udf_missing_var.stable.out
sql/test/subquery/Tests/subquery5.stable.err
sql/test/subquery/Tests/subquery5.stable.out
Removed Files:
debian/fix-deb.sh
Modified Files:
clients/Tests/exports.stable.out
clients/mapiclient/mclient.c
clients/mapiclient/stethoscope.c
clients/mapilib/mapi.c
clients/mapilib/monetdb-mapi.pc.in
common/stream/stream.c
common/stream/stream.h
common/utils/mcrypt.h
common/utils/mutils.h
configure.ag
debian/monetdb5-sql.install
gdk/Makefile.ag
gdk/gdk.h
gdk/gdk_aggr.c
gdk/gdk_bat.c
gdk/gdk_batop.c
gdk/gdk_calc.c
gdk/gdk_group.c
gdk/gdk_join.c
gdk/gdk_private.h
gdk/gdk_time.h
gdk/gdk_unique.c
gdk/gdk_utils.c
gdk/gdk_utils.h
monetdb5/modules/atoms/json.c
sql/backends/monet5/UDF/capi/capi.c
sql/backends/monet5/UDF/pyapi3/conversion3.c
sql/backends/monet5/rel_bin.c
sql/backends/monet5/sql_cat.c
sql/backends/monet5/sql_gencode.c
sql/backends/monet5/sql_statement.c
sql/server/rel_exp.c
sql/server/rel_optimizer.c
sql/server/rel_psm.c
sql/server/rel_schema.c
sql/server/rel_select.c
sql/server/rel_unnest.c
sql/server/rel_updates.c
sql/server/sql_mvc.c
sql/server/sql_query.c
sql/server/sql_query.h
sql/storage/store.c
sql/test/BugTracker-2017/Tests/side-effect.Bug-6397.stable.out.single
sql/test/miscellaneous/Tests/All
sql/test/miscellaneous/Tests/declared_tables.sql
sql/test/miscellaneous/Tests/declared_tables.stable.err
sql/test/miscellaneous/Tests/declared_tables.stable.out
sql/test/miscellaneous/Tests/groupby_error.sql
sql/test/miscellaneous/Tests/groupby_error.stable.out
sql/test/miscellaneous/Tests/simple_selects.sql
sql/test/miscellaneous/Tests/simple_selects.stable.err
sql/test/miscellaneous/Tests/simple_selects.stable.out
sql/test/subquery/Tests/subquery3.sql
sql/test/subquery/Tests/subquery3.stable.err
sql/test/subquery/Tests/subquery3.stable.out
sql/test/subquery/Tests/subquery5.sql
tools/merovingian/daemon/forkmserver.c
tools/merovingian/daemon/handlers.h
Branch: unlock
Log Message:

Merge with default branch.


diffs (truncated from 5415 to 300 lines):

diff --git a/clients/Tests/exports.stable.out b/clients/Tests/exports.stable.out
--- a/clients/Tests/exports.stable.out
+++ b/clients/Tests/exports.stable.out
@@ -9,7 +9,7 @@ stdout of test 'exports` in directory 'c
 int ALIGNsynced(BAT *b1, BAT *b2);
 int ATOMallocate(const char *nme);
 void *ATOMdup(int id, const void *val);
-uint8_t ATOMelmshift(int sz);
+uint8_t ATOMelmshift(int sz) __attribute__((__const__));
 char *ATOMformat(int id, const void *val);
 int ATOMindex(const char *nme);
 size_t ATOMlen(int id, const void *v);
@@ -319,7 +319,7 @@ size_t GDKuniqueid(size_t offset);
 gdk_return GDKupgradevarheap(BAT *b, var_t v, bool copyall, bool mayshare) 
__attribute__((__warn_unused_result__));
 lng GDKusec(void);
 int GDKverbose;
-const char *GDKversion(void);
+const char *GDKversion(void) __attribute__((__const__));
 size_t GDKvm_cursize(void);
 void *GDKzalloc(size_t size) __attribute__((__malloc__)) 
__attribute__((__alloc_size__(1))) __attribute__((__warn_unused_result__));
 void HASHdestroy(BAT *b);
@@ -441,33 +441,33 @@ BAT *canditer_slice(struct canditer *ci,
 BAT *canditer_slice2(struct canditer *ci, BUN lo1, BUN hi1, BUN lo2, BUN hi2);
 int closedir(DIR *dir);
 char *ctime_r(const time_t *restrict, char *restrict);
-date date_add_day(date dt, int days);
-date date_add_month(date dt, int months);
-int date_century(date dt);
-date date_create(int year, int month, int day);
-int date_day(date dt);
-int date_dayofweek(date dt);
-int date_dayofyear(date dt);
-int date_decade(date dt);
-int date_diff(date d1, date d2);
+date date_add_day(date dt, int days) __attribute__((__const__));
+date date_add_month(date dt, int months) __attribute__((__const__));
+int date_century(date dt) __attribute__((__const__));
+date date_create(int year, int month, int day) __attribute__((__const__));
+int date_day(date dt) __attribute__((__const__));
+int date_dayofweek(date dt) __attribute__((__const__));
+int date_dayofyear(date dt) __attribute__((__const__));
+int date_decade(date dt) __attribute__((__const__));
+int date_diff(date d1, date d2) __attribute__((__const__));
 ssize_t date_fromstr(const char *buf, size_t *len, date **d, bool external);
-int date_month(date dt);
-in