Jun2020 (11.37)

Jun2020-SP1 bugfix release (11.37.11)

MonetDB Common

  • Hash buckets come in variable widths. But if a BAT grows long enough so that the BAT indexes that are stored in the buckets don’t fit anymore, the buckets need to be widened. This is now fixed.

Bug Fixes

  • 6844: sys.getUser('https://me:pw@www.monetdb.org/Doc') does not return the user: me
  • 6845: the url sys.get… functions do not allow null as a parameter
  • 6858: json.keyarray(json ‘{ “":0 }’) fails with error: Could not allocate space
  • 6859: only first character of the separator string in json.text(js json, sep string) is used
  • 6873: sys.hot_snapshot() creates incomplete snapshots if the write-ahead log is very large
  • 6876: tar files created by sys.hot_snapshot() produce warnings on some implementations of tar
  • 6877: MonetDB produces malformed LZ4 files
  • 6880: Left fuzzy queries are much slower than other fuzzy queries.
  • 6882: cgroups limits no longer respected?
  • 6883: SQLancer crash on delete query
  • 6884: SQLancer generates query with unclear error message
  • 6885: SQLancer causes assertion error on UTF8_strlen
  • 6886: SQLancer alter table add unique gives strange error message
  • 6887: SQLancer crash on complex query
  • 6888: SQLancer crash on cross join on view
  • 6889: SQLancer crash on long query
  • 6892: SQLancer crash on query with HAVING
  • 6893: SQLancer inner join reporting GDK error
  • 6894: SQLancer crash on rtrim function
  • 6895: SQLancer causing ‘algebra.select’ undefined error
  • 6896: SQLancer algebra.select’ undefined 2
  • 6897: SQLancer distinct aggregate with error on group by constant
  • 6898: SQLancer crash on join query
  • 6899: SQLancer TLP query with wrong results
  • 6900: SQLancer generated SIGFPE
  • 6901: SQLancer TLP query with wrong results 2
  • 6902: SQLancer query: batcalc.between undefined
  • 6903: SQLancer calc.abs undefined
  • 6904: SQLancer aggr.subavg undefined
  • 6905: SQLancer TLP query with wrong results 3
  • 6906: SQLancer crash on complex join
  • 6907: SQLancer algebra.select undefined
  • 6908: SQLancer inputs not the same size
  • 6909: SQLancer query with wrong results
  • 6911: SQLancer query: ‘calc.bit’ undefined
  • 6917: Decimal parsing fails
  • 6918: SQLancer query compilation error
  • 6919: SQLancer insert function doesn’t handle utf-8 strings
  • 6920: SQLancer project_bte: does not match always
  • 6922: Timestamp columns not migrated to new format
  • 6923: Imprints data files for timestamp BAT not migrated to the new format
  • 6924: SQLancer query copy on unique pair of columns fails and complex query with GDK error
  • 6925: Count string rows in union of string tables leaks (RSS) memory
  • 6926: SQLancer query with wrong results
  • 6927: SQLancer inputs not the same size
  • 6928: SQLancer crash on coalesce
  • 6929: SQLancer calc.date undefined
  • 6932: Syntax error while parsing JSON numbers with exponent
  • 6934: sys.isauuid() returns wrong answer for some invalid uuid strings

Jun2020 feature release (11.37.7)

MonetDB5 Server

  • The mserver5 option –verbose (-v) was removed. A similar effect can be had by issuing the query CALL logging.setcomplevel(‘SQL_TRANS’, ‘INFO’); as the monetdb user.
  • The functions algebra.intersect, algebra.semijoin, and algebra.crossproduct have an extra argument, bool max_one, which indicates that there must be no more than one match in the join.
  • The example module opt_sql_append is not installed in the binary packages anymore.
  • Added mserver5 option (–dbtrace=) in order to be able to specify the output file any produced traces.
  • Removed function bat.setKey().
  • algebra.rangejoin now has two extra arguments: anti:bit and symmetric:bit.
  • Added session identifier, number of workers and memory claim to the sysmon queue.
  • The worker (number of threads), memory (in MB) and optimizer pipeline limits can now be set per user session basis. The query and session timeouts are now set in seconds.
  • With required privileges an user can set resource limits for a session.
  • There are now versions of group.(sub)group(done) that produce a single output containing just the groups.
  • algebra.join and algebra.leftjoin now have forms which return a single column. The column that is returned is the left column of the two column version.
  • The MAL profiler now assigns the SQL TRACE output to the client record thereby avoiding the interaction with other queries, but loosing insight of competing queries. The stethoscope should be used for that.

SELinux Support

  • There was a problem with the MonetDB SELinux support on Fedora 32. That is fixed in this release. In order to do a proper upgrade of the package if you have already installed MonetDB-selinux on Fedora 32, you may need to uninstall (dnf remove) the old package and then install the new.

Whole System

  • 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 debug output is written. The default value is the file mdbtrace.log inside the database directory. This option can also be set through the monetdb program.
  • The home directory of the automatically created monetdb user was changed from /var/MonetDB to /var/lib/monetdb (RPM based systems only). This home directory is (currently) not used for anything, though.
  • Python 2 support has been removed. There is now only support for using Python 3.
  • Removed support for bam and sam files.
  • Added mserver5 option (–set raw_strings=true|false) and monetdb database property (raw_strings=yes|no) to control interpretation of strings.

Merovingian

  • On Fedora and RHEL systems (not RHEL 6), if monetdbd runs under systemd, when the package is updated, monetdbd (and hence any mserver5 process it runs) is restarted.
  • Added dbtrace mserver5 option to the daemon in order to set mserver5’s output directory for the produced traces.

Client Package

  • The monetdb-client-tools (Debian/Ubuntu) and MonetDB-client-tools (Fedora/RH) containing the stethoscope, tachograph, and tomograph has been removed. A completely new version of stethoscope will be released to replace the old version.
  • Removed the possibility of using the MD5 checksum for authentication purposes. It was never actively used but was there as an option. Now the option has been removed.
  • Add port and host as fields in the .monetdb file.
  • Added ‘sessionid’ column to system function sys.queue(), so each query gets tagged with the current session identifier
  • Allow monetdb user to control session and query time out and selectively stopping a client sessions with a soft termination request.

ODBC Driver

  • The NUMERIC and FLOAT types are now handled fully. Before only DECIMAL, FLOAT, and DOUBLE were handled fully.
  • Some bugs were fixed in the passing back and forth between application and server of values of type GUID (UUID).

MonetDB Common

  • The functions BATintersect, BATsemijoin, and BATsubcross have an extra argument, bool max_one, which indicates that there must be no more than one match in the join.
  • The “unique” property on BATs was removed. The property indicated that all values in a BAT had to be distinct, but this was not actually used.
  • A new type of candidate list has been introduced. Candidate lists are used internally to specify which rows of a column participate in an operation. Before, candidate lists always contained a list of candidate row IDs. The new candidate list type specifies a list of row IDs that should NOT be considered (negative candidates).
  • The maximum number of BATs in the system has been increased for 64 bit architectures.
  • The hash tables used internally by the system now uses a technique based on Linear Hashing which allows them to grow gracefully. This means that hash tables aren’t removed and recreated nearly as often anymore. This also meant that the hash table had to be split into two files, which means that after an upgrade the hash tables have to be recreated.
  • Implemented a version of BATproject, called BATproject2, with two “right” arguments which conceptually follow each other.
  • Removed MT_mmap and MT_munmap from the list of exported functions. Use GDKmmap and GDKmunmap with the same parameters instead.
  • Changed the interface of the atom “fix” and “unfix” functions. They now return a value of type gdk_return to indicate success/failure.
  • Removed the tunique property. The tunique property indicated that all values in the column had to be distinct. It was removed because it wasn’t used.
  • BATrangeselect now has two extra arguments: anti and symmetric (both bool).

SQL Frontend

  • Updating the value of a sequence now requires privilege on its own schema.
  • The sys.querylog_enable(threshold integer) now actually enables the querylog and uses a threshold in milliseconds.
  • Removed UNION JOIN statements. They were dropped by the SQL:2003 standard, plus MonetDB implementation was not fully compliant.
  • The OFFSET value in the COPY INTO query now counts uninterpreted newlines. Before it counted “unquoted record separators” which meant that if you had a single quote on a line that you want to skip, you could not use the feature.
  • Added support for FROM RANGE MINVALUE TO RANGE MAXVALUE and FROM RANGE MINVALUE TO RANGE MAXVALUE WITH NULL VALUES cases in partitioned tables by range (before they weren’t).
  • Removed support for Python 2. Python 2 itself is no longer supported. Use Python 3 instead. Functions that were declared as LANGUAGE PYTHON2 or LANGUAGE PYTHON2_MAP are changed to LANGUAGE PYTHON and LANGUAGE PYTHON_MAP respectively (without changing the Python code).
  • Implemented ‘covar_pop’ and ‘covar_samp’ aggregate functions, as well as their window function counterparts. Implemented ‘stddev_samp’, ‘stddev_pop’, ‘var_samp’, ‘var_pop’, ‘corr’ and ‘group_concat’ window function correspondents.
  • Extended SQL catalog with CREATE WINDOW syntax for user-defined SQL:2003 window functions. At the moment, window functions must be defined on the backend engine, i.e. on this case MAL. In the current implementation, the backend code generation creates two additional columns of type lng with the start and end offsets for each row.
  • Added prepared_statements_args view, which details the arguments for the prepared statements created in the current session.
  • Added sys.prepared_statements view, which lists the available prepared statements in the current session.
  • Added deallocate statements with the syntax ‘DEALLOCATE [PREPARE] { number | ALL }’, to close an existing prepared statement or all, through the SQL layer. Previously this feature was available via MAPI exclusively with the “release” command.
  • Added support for raw strings using the syntax r’’ or R’’. This means that C-like escapes will remain uninterpreted within those strings. For instance SELECT r’"’ returns a string of length two. The user needs to escape single quotes by doubling them: SELECT r’’’’.
  • Implemented ROLLUP, CUBE and GROUPING SETS from SQL:1999. They define grouping subsets used with the GROUP BY clause in order to compute partial groupings. Also, the GROUPING aggregate was added. This aggregate is a bitmask identifying the grouping columns not present in the generated grouping row when used with the operators described above.
  • Updated user session procedures by adding the possibility to set properties based on a session identifier. Optimizer pipeline: sys.setoptimizer(int, string) Number of worker threads: sys.setworkerlimit(int, int) Memory limits (in MB): sys.setmemorylimit(int, int) Query timeout (in ms): sys.setquerytimeout(int, int) Session timeout (in ms): sys.setsessiontimeout(int, int) The first argument corresponds to the id of the session to modify, and these procedures are bound to the monetdb user exclusively. The versions of the mentioned procedures with just the second argument were added as well, where the changes are reflected in the current user session, and therefore every user can call them.
  • The procedures sys.settimeout(bigint), sys.settimeout(bigint,bigint) and sys.session(bigint) are now deprecated. Instead use sys.setquerytimeout and sys.setsessiontimeout mentioned above.
  • Added SQL procedure sys.hot_snapshot() which can be used to write a snapshot of the database to a tar file. For example, call sys.hot_snapshot(’/tmp/snapshot.tar’);. If compression support is compiled in, snapshots can also be compressed (’/tmp/snapshot.tar.gz’). The tar file expands to a single directory with the same name as the database that was snapshotted. This directory can be passed directly as the –dbpath argument of mserver5 or it can be copied into an existing dbfarm and started from monetdbd.

Bug Fixes

  • 6298: unexpectedly slow execution of SELECT length(fieldname) FROM tablename LIMIT 1 queries
  • 6401: Suspected memory leak in mserver5 when creating/dropping tables
  • 6687: Count distinct very slow and use too much the hard drive
  • 6723: columns aliases duplicates should not be allowed. automatic aliasing required.
  • 6731: Add system view to allow querying of available prepared statements and their parameters
  • 6732: Add SQL command to close a specific prepared statement
  • 6750: Executing a query on a non-existing column on a remote table crashes the remote server
  • 6785: function sys.isaURL(url) should have been declared as sys.isaURL(string)
  • 6808: reveal the alarm.sleep procedure in SQL
  • 6813: function not_uniques(bigint) returns error when called
  • 6818: usage of multiple column expressions in where-clause (f(a), f(b)) in (select a, b) causes assertion failure on mserver5
  • 6821: Failed to start monetdb with embedded python
  • 6828: Server crashes when executing a window query with ordering by EXTRACT date
  • 6846: Global temporary table not accessible in other connections / sessions
  • 6847: A simple way of speeding up impscheck for dense canditers
  • 6850: Idle timestamp not set
  • 6851: json parser doesn’t parse integers correctly
  • 6863: thash files not released upon drop table
  • 6864: (I)LIKE with multiple % doen’t find matches