Skip to content

kdb+ 3.4 Release Notes

This page details the latest features and improvements released to kdb+ 3.4.

2019.06.03

Fixes and improvements

  • .j.j was not escaping symbols as it was char vectors. e.g.

    q)(2#enlist x)~.j.k .j.j(`$;::)@\:x:"A\\B"
  • kdb+ is not yet compatible with openssl 1.1.x due to openssl breaking their binary api; kdb+ seg faulted if openssl 1.1.x was loaded.

    Now, if openssl 1.1.x is detected, it is ignored.

2019.02.07

New

  • remote connections using the "qcon" text protocol are now routed to .z.pq, which defaults to calling .z.pi.

    This allows a user to handle remote qcon connections (via .z.pq) without defining special handling for console processing (via .z.pi).
    see https://code.kx.com/q/cookbook/firewalling for locking down message handlers.

Fixes and improvements

  • avg for char vector could crash if the vector contained a null. e.g.

    q)81.5~avg 7500000#"abc "
  • hcount`:dir was reporting an unrelated error string on unix, since 3.4t 2015.09.25.

  • ipc messages with an invalid header length field of <8 bytes was corrupting memory resulting in a crash. Now throws 'badMsg.

  • json serializer was not generating correct json for control chars. e.g.

    q)"\"one\\u0013\""~.j.j "one\023"
  • listening on 0.0.0.0 was not listening on any interface, other than the unix domain socket, twice. e.g.

    q)\p 0.0.0.0:5010
  • flip could create a table with zero columns which could cause a crash later. Now throws 'rank. e.g.

    q)@[flip;(0#`)!([]());"rank"~]
  • on windows only, hopen with timeout could be erroneous if there was a TLS connection active.

  • on windows only, if kdb+ opened or accepted >64 connections and at least one of them used TLS, it could crash.

  • an error thrown from a function during multi-arg (>2 args) scan or each could leak memory. e.g.

    q){$[x>2;'`e;x+y+z]}\[0;til 5;til 5]
    q){$[x>2;'`e;x+y+z]}'[til 5;til 5;til 5]
  • kdb+ would crash when printing to console if on startup the environment variables LINES or COLUMNS was set to "".

  • invalid (.e.g non-unique or partial) enum domains could cause a crash with grouped selects. e.g.

    q)sym:`a`b;0!select by x,x1 from([]`sym!2 0N 2 0N;til 4;til 4)

2017.07.31

Fixes and improvements

  • reassigning a view during its calculation could result in a crash. e.g.

    q)a::@[value;`.a;a:1 2 3]
  • improved performance of pattern select ... by sym from t where sym in ... with p or g attr on sym and few rows per distinct sym. e.g.

    q)`:t/ set([]x:`p#til 10000000;y:10000000?0xff);z:-20?get`:t/x;system"ts select max y by x from get`:t where x in z"
  • socket broadcast, -25!(handles;msg) was leaking a ref count on (::) which would cause a random crash later. e.g.

    q)-25!(handles;msg);-16!(::)

2017.07.19

Fixes and improvements

  • compressed messages were not length limit checked for older clients (c.o, or kdb+ prior to v3.4), causing the client to crash.

  • raze of a dictionary could throw 'type error when the value of the result is a mixed list. e.g.

    q)d:(enlist 0)!enlist 0;e:1 2!`a`b;(0 1 2!(0;`a;`b))~raze(d;d;d;e)
  • was leaking memory for failed column amend, since v2.x. e.g.

    q)t:([]1 2 3);@[t;`x;+;"a"]
  • upserting to ondisk `g#() was not checking for certian errors. e.g.

    q)`:x set`g#();.[upsert;(`:x;([]0 1));"rank"~]

2017.05.03

Fixes and improvements

  • loading shared libraries (e.g. qml) on unix platforms could cause a crash if the code was using _IO_stdin.

  • on windows, hopen with timeout would always throw timeout if the connection was not accepted. e.g.

    q)hopen(`::4444;5000) / if nothing listening on 4444 'timeout after 5 seconds
  • select avg x by y from t was incorrect for nested x since v3.4 2016.11.18. e.g

    q)([a:`a`b]b:enlist each 4 5.)~select avg b by a from([]a:10#`a`b;b:1 cut til 10)
  • check lengths of dictionary result from indexing, as different lengths can cause a crash later. e.g.

    q)@[([b:0 1]a:0 1).;(::;`c);{"length"~x}]
  • distinct on a vector of longs with more than 2 billion uniques was causing wsfull|crash. e.g.

    q)distinct til prd 31#2
  • .z.W was not deducting sent data from a queued message.

  • hopen again checks symbol is a path. Was not checking since kdb+3.4 2016.05.31.

    q)hopen`file / throws 'type

2017.03.13

Fixes and improvements

  • exported ee as part of c-api.

  • select[<c] .. by ... could leak memory when <c failed. e.g.

    q)select[>c] by a from ([]a:0 1;b:0 1)

2017.03.01

Fixes and improvements

  • select ... by time.minute could crash or wsful if time was sorted and of type datetime, timestamp or timespan. e.g.

    q)select by time.minute from([]time:`s#2#.z.p)
  • the json serializer .j.j now serializes (::) to "null". e.g.

    q)"null"~.j.j(::)
  • updating a file in place was leaking a ref count. e.g.

    q)`:a set 10#0b;@[`:a;2 3;:;11b];-16!(::)
  • update could leak a ref count for (::) if target type did not match. e.g.

    q)@[value;"update raze a from([]a:enlist enlist[`a]!enlist 0)";{}];-16!(::)
  • ipc msg validation could crash under some rare scenarios if given a malformed msg with incorrectly large length fields.

    q)@[-9!;@[-8!(0#0;1#0);15+til 12;:;0x806653b07bf67d07186f53b0];{"badmsg"~x}] / was crashing

2017.02.11

Fixes and improvements

  • ipc msg validation could crash under some rare scenarios if given a malformed msg.

  • websocket client was sensitive to the case of the response headers sec-websocket-accept and sec-websocket-extensions.

  • -25!(h;::) was not flushing the internal send buffers for each handle in h.

  • setting an s attr on a vector which had a g attr and no other references was leaking memory, or removing the g attr on the original. e.g.

    q)`s#`g#til 1000 / leaked mem
    q)v:`g#`a`b;b:`s#v!1 2;`s`g~attr each(b;v) / dropped g attr
  • appending a sorted vector to an empty list was changing the s attr to g on the input. e.g.

    q)v:`s#1 2 3;b:`g#();b,:v;`s`g~attr each(v;b)
  • json serializer (.j.j) did not wrap keys in quotes for some types. e.g.

    q)(`0`1!0 2f)~.j.k .j.j 0 1!0 2
  • desc sort of a char vector was relatively much (~50x) slower than asc. e.g.

    q)a:10000000?`char$97+til 26;system each("t asc a";"t desc a")
  • http get did not allow for a result with a specified content-length > 2GB. e.g.

    q).Q.hg`$"http://data.sdss3.org/sas/dr12/sdss/spectro/redux/specObj-dr12.fits"

2017.01.17

Fixes and improvements

  • linux builds were not detecting enabled number of cores correctly since v3.4, 2017.01.16.

2017.01.16

Fixes and improvements

  • reduced symbol visibility in binary to avoid clashes with other dynamically loaded code.

  • hopen port now checks that port is within 0..65535. e.g.

    q)hopen 0N / domain error
  • processing an http post with incorrect Content-length field could cause a crash. e.g.

    q)system"\p 14999";.z.pp:{0N!x 0} / server process
    q)`:http://127.0.0.1:14999"POST / HTTP/1.0\r\nContent-length: 150\r\n\r\n",251?.Q.a / client process
  • allow case to work with I type. e.g.

    q)1 20 100~0 1 2i'[1 2 3;10 20 30;100]
  • q.k - .z.ph now returns HTTP/1.1 400 Bad Request response for uncached paging request. e.g.

    curl -i --raw "http://127.0.0.1:5000/?\[=1"
  • updating mappable files in situ was adjusting memory usage tally incorrectly, since v3.4 2016.02.02. e.g.

    q){a:.Q.w[]`mmap;`:file set til 10;@[`:file;2 4 6;:;10 20 30];hdel`:file;a~.Q.w[]`mmap}[]

2016.12.23

Fixes and improvements

  • keyedTable%atom was throwing 'nyi since v3.4 2016.09.26. e.g.

    q)([a:`a`b`c]b:0 .1 .2)~([a:`a`b`c]b:til 3)%10

2016.12.16

Fixes and improvements

  • x in Y was throwing type error when Y was length 1 and different type to x. It should have behaved as x in first Y, since v3.4 2016.06.19. e.g.

    q)(~). 1 2 3h in/:(enlist;::)@\:1

2016.12.14

Fixes and improvements

  • q.k - .Q.fc was returning additional empties when count[rhs]<number of slave threads, since v3.3 2015.02.12. e.g.

    q).Q.fc[0N!]til 3; / start with q -s 4
  • triadic (and above) scan leaked memory when its result is empty, since v1.0. e.g.

    q){0N!.Q.w[]`used;value x;0N!.Q.w[]`used;}"{x+y+z}\\[0 1;();()]"

2016.12.08

Fixes and improvements

  • select from t where x in y was slow for large x with g attr, and small y, since v3.4 2016.03.29. e.g.

    q)t:([]`g#6000000?500000i);system"ts select from t where x in enlist 5i"
  • .Q.gc[] leaked 16 bytes on each invocation when slave threads are in use.

    q).Q.gc[];0N!.Q.w[]`used;do[100;.Q.gc[]];0N!.Q.w[]`used;
  • json parser is now RFC7159 compliant, in that it allows values at root, outside of [] and {}. e.g.

    q).j.k each ("true";"false";"null";"12";"12.3";"\"hello\"")
  • json parser requires a digit after a . for a floating point number. e.g.

    q).j.k "12." // is an error

2016.11.18

Fixes and improvements

  • extend where to accept I in addition to J. e.g.

    q)1 2 2~where 0 1 2i
  • avg could overflow during select avg x by group for 32bit int type, since v3.3 2015.04.13. e.g.

    q)([y:1#0]x:1#1000000.)~select avg x by y from([]1000000#1000000i;y:1000000#0)
  • extend = to work with types above 99h; previously threw 'type. e.g.

    q)all{x=x}each({};neg;(+);(\);1+;1+2+;{}';{}/;{}\;{}':;{}/:;{}\:)

2016.11.07

Fixes and improvements

  • allow "P"$ to parse date only with delimiters "./ -", same as "Z"$.

    q)enlist[2012.12.31]~distinct raze"d"$"PZ"$\:/:@["2012 12 31";4 7;:;]@/:"./ -"
  • remove unix domain file in /tmp/kx.[0-9]+ on crash.

  • if listen on a unix domain socket fails, it now throws a more explicit error msg:

    "'cannot listen on uds /tmp/kx.9000. OS reports: Address already in use"
  • Allow user to disable listening on unix domain socket, or change default path from /tmp using env var QUDSPATH. e.g.

    q)system"p 0";setenv[`QUDSPATH;""];system"p 6000" / disables listening on unix domain socket
    q)system"p 0";setenv[`QUDSPATH;"/home/kdbuser"];system"p 6000" / use /home/kdbuser as path

2016.10.27

Fixes and improvements

  • http requests could cause memory corruption when .z.ph is not defined.

  • check type of arg to value. e.g.

    q)value 1 / now throws 'type
  • stack overflow ('stack) leaked memory. e.g.

    q)@[value;"x:`x@;x`";{(.Q.w[]`used)}]
  • raze (,/) could corrupt memory resulting in a later crash when passed a mixed list which contained a table. e.g.

    q)\ts:100 raze a:(0;([]a:0#0);([]b:0#()))
  • select from t where sym in () skirted optimization since 3.4t 2016.04.11. e.g.

    q)t:update `g#sym from([]sym:2000000?`7);system"\t select from t where sym in ()"

2016.10.10

Fixes and improvements

  • q.k re-released to correct map-reduce avg fn on partitioned table using missing varable `x. e.g.

    q)select avg p by sym from t
  • updating mappable files in-place was erroneously blocked for boolean vectors, e.g.

    q)`:a set 10#0b;@[`:a;2 3;:;11b];get[`:a]~@[10#0b;2 3;:;11b]

2016.09.26

New

  • added support for parsing 15 chars of digits representing HHMMSSmmmuuunnn as timespan or time. e.g.

    q)"NT"$\:"123456123987654"

Fixes and improvements

  • upserting to a keyed table with the first column as a list with no attribute was crashing since 2016.08.22. e.g

    q)t:([a:1#enlist"";b:1#`]c:1#0N;d:1#0N); `t upsert `a`b`c!({};`;1);
  • J div j and F%f had precision errors, since v3.4 2015.11.20. e.g.

    q)all(enlist[30]~(1#3000000000000)div 100000000000;enlist[0f]~-30+enlist[3000000000000.]%100000000000.)
  • divide on temporal types was not returning float. e.g.

    q){(1#x;x)}[0.00010230141846745273]~{((1#x)%y;x%y)}[2016.09.21;16:35:05.917]
  • .q.k the count in avg was not ignoring nulls during map/reduce for a partitioned table. e.g

    q)t:([]1 2 0N 0N);.Q.dpft[`:hdb;;`x;`t]each .z.d-til 2;system"l hdb";
    q)(exec distinct x from select avg x by date from t)~exec x from select avg x from t
  • q.k - .Q.bv did not accept totally empty dirs. e.g.

    q)`:dbx/par/par.txt 0:("../0";"../1");`:dbx/0/2016.01.01/t/ set([]0 1);
    q)`:dbx/1/2016.01.02/z set 0;hdel`:dbx/1/2016.01.02/z;system"l dbx/par";.Q.bv[]
  • parsing key value pairs with 0: now allows J in addition to I+S. In 3.x I is an alias for J in this construct. e.g.

    q){x~y}.("IJ",\:"=|")0:\:"1=a|2=b"
  • distributed peach was causing an error for .Q.gc[]. e.g.

    q).z.pd:`u#0#0;.Q.gc[]
  • `hh$x was erroneously using mod 60 instead of 24. e.g.

    q)(5#12i)~`hh$12:00+0D+til 5

2016.08.22

Fixes and improvements

  • multi column table lookup was not utilizing attribute if first column was a list. e.g.

    q)n:500000;t:([a:`g#string n?`8;b:n#til 8]c:til n);system"ts t(key t)2?n"

2016.08.04

(re-released with updated q.k)

Fixes and improvements

  • q.k - meta was broken for partitioned tables if .Q.bv[] were not called first, since initial 2016.08.04 release.

  • set file permission to 0666 for unix domain sockets created as /tmp/kx.PORTNUMBER.

  • q.k - differ was not returning a boolean vector for differ().

  • q.k - .Q.bv now retains attributes for prototypes.

  • q.k - meta was not working in combination with .Q.bv[] if prototype was not present in latest partition. e.g.

    q)`:test/2016.01.01/t/ set([]`s#til 10);system"mkdir test/2016.01.02";system"l test";.Q.bv[];meta t
  • initial state derived from 0n|0ne was not initializing correctly for 0n f/F and 0ne f/E, where f is +|*|or|and. e.g.

    q)all(1f~0n or/0 1f;-0w~0n or/0#0f;1f~0n+/0 1f;0f~0n+/0#0f;1f~0n*/0#0f;2f~0n*/1 2f)
  • error message for failure on hopen for fifo was not stripping a leading / slash correctly. e.g.

    q)hopen`:fifo://proc/cpuinfo / should be hopen`:fifo:///proc/cpuinfo

2016.07.19

Fixes and improvements

  • restore SIGPIPE handling to default when creating a child process. e.g.

    q)system"dd if=/dev/zero of=sigpipedata.dat count=1024 bs=1024>&/dev/null;gzip -f sigpipedata.dat -S .Z;zcat sigpipedata.dat|head -c 5"
  • select was erroneously throwing 'type for queries on parted column, then <,>,<=,>= on time column if time column was of timestamp type. e.g.

    q)select from([]sym:`p#`a`a`b;time:"p"$0)where sym=`a,time<=15:50:59

2016.07.11

Fixes and improvements

  • block erroneous update of keyed table leaving key columns of a different length to that of the value columns (it could crash later). e.g.

    q)update a:til 100 from([a:til 5];b:(`a;`b`c;`d;`e;`f))
  • using empty nested data types on disk could seg fault with some ops. e.g.

    q).Q.Xf["C";`:a];`:b set get`:a
  • setting p attribute on vector of floats which contained more than one null was throwing u-fail, since 2016.05.24. e.g.

    q)`p#0 0n 0n
  • p attr info for datetime vectors could be incorrect if values within comparison tolerance, resulting in inconsistent data or a crash, since v1.0. e.g.

    q){(~). distinct each(`p#x;x)}@"z"$-0.057692307692307709 -0.057692307692307654 / fails test
    q)group`p#"z"$-0.057692307692307709 -0.057692307692307654 / crash
  • restrict assumption of time being sorted within a block to sym column with s or p attr only. e.g.

    q)select from flip`date`time`currency!(`s#2016.04.05 2016.04.05;08:56:50.000 07:39:24.000;`GBp`GBp)where date=2016.04.05,time<07:59:00

2016.06.27

Fixes and improvements

  • zlib+snappy compression could crash|throw errors if first used from a slave thread.

  • functional select was not returning expected columns for splayed tables if the final arg was an empty dict. e.g.

    q)`:t/ set([]a:0 1;b:0 1);?[`:t/;();0b;]@/:(();()!())
  • scalar extend lhs for wavg. e.g.

    q)2f~1 wavg 1 2 3

2016.06.21

Fixes and improvements

  • .Q.bv[] erroneously required tables to be present in all segments.

  • list in atom with atom type > 99 was throwing 'type since 2016.06.19. e.g.

    q)10b~({};{x})in{}

2016.06.19

Fixes and improvements

  • further correction to in with infinities, 0w -0w in/: -0w 0w was not matching. e.g.

    q)11b~0w -0w in/: -0w 0w
  • shortened ema to {(*y)(1f-x)\x*y}.

2016.06.14

Fixes and improvements

  • `::"" was causing kdb+ to exit if no socket open, or at best throw a 'snd error. Now routes to handle 0.

  • avoid grsec error:"denied resource overstep by requesting 1024 for RLIMIT_NOFILE".

  • 0w in 0w and -0w in -0w were not matching correctly. e.g.

    q)11b~(0w in 0w;-0w in -0w)
  • lists of conforming dictionaries from group by were causing throwing a type error, since 3.4t 2016.02.17. e.g.

    q)([c:`x`y]d:([]a:1#'0 1;b:1#'2 3))~select d:`a`b!(a;b)by c from([]a:0 1;b:2 3;c:`x`y)

2016.06.05

Fixes and improvements

  • added scov,sdev to .Q.res.

  • amending vectors in-situ on disk was not detecting/reporting errors correctly.

  • throw 'domain when setting random number generator seed with invalid seed 0. e.g.

    q)\S 0

2016.06.02

Fixes and improvements

  • update was erroneously creating a column of type table instead of the equivalent list of dictionaries, since 3.4t 2016.02.17. e.g.

    q)(([]a:1#`a;b:enlist`a`b!1 2))~update b:enlist[`a`b!1 2]from([]a:(),`a;b:enlist())where a=`a

2016.05.31

First production release of kdb+ 3.4.

New

  • allow user to specify how many bytes to read from a fifo. e.g.

    q)h:hopen`:fifo:///dev/random;0N!read1(h;8);hclose h

Fixes and improvements

  • correct .Q.fsn to expect a path pattern (`:...).

2016.05.28

Fixes and improvements

  • corrected fifo uri inside .Q.fsn to use `:fifo:// pattern;

  • .Q.hg expects symbol arg (https works with some proxies that do not expect 'CONNECT'). e.g.

    q).Q.hg`:www.kx.com
  • varchar~\:x and x~/:varchar were incorrect for on-disk nested char vectors, since 2016.05.26

  • 100b~(get`:nested set("abcd";"abcdef";"bcde"))~\:"abcd"

  • ipc msgs were limited to 2GB on osx.

2016.05.26

New

  • improved performance by ~10x for varchar~\:x and x~/:varchar given x as list of char vectors (on disk or in-mem).

    This is ~2x faster than like. e.g.
    q)m:1000 12#"asdf";v:"asd";n:100000;system each("t:n m~\\:v";"t:n v~/:m";"t:n m like v")
  • Added .Q.hp, for http POST. e.g.

    q).Q.hp[`:http://url;"mime/type"]"payload"
  • .Q.hg can use http proxies (https with proxies is nyi).

Fixes and improvements

  • uri prefix for unix domain sockets, fifos and tls connections has changed to `:unix://port, `:fifo://filename and `:tcps://host:port.

    Allows single-shot sync requests a la `:unix://port "2+2"
  • select with a group by sorted time was returning badly formed result (with potential crash) if it was not the only grouped column. e.g.

    q)([minute:`p#00:00 01:00;s:`a`b];p:3 4f)~select p:first p by time.minute,s from([]time:`s#0 1 1t;s:`a`b`b;p:3 4 5f)
  • updating files in situ was leaking memory since 2016.02.02. e.g.

    q)`:file set til 10;@[`:file;2 4 6;:;10 20 30]

2016.05.24

New

  • improved performance by ~10x for 'like' on nested char vectors on disk. e.g.

    q)a:first x:get .[`:nestedChars;();:;1000 12#97?" "];system"t:1000 x like a"
  • .h.tx has raw option to return text as is, to support json as a single object. e.g.

    http://host:port/.raw?.j.j@table

Fixes and improvements

  • p attr info for float vectors could be incorrect if values within comparison tolerance, resulting in inconsistent data or a crash, since v1.0. e.g.

    q){(~). distinct each(`p#x;x)}@-0.057692307692307709 -0.057692307692307654 / fails test
    q)group`p#-0.057692307692307709 -0.057692307692307654 / crash
  • hopen without timeout was crashing since 2016.05.12

2016.05.16

NUC (Not Upwardly Compatible)

Not backward compatible. Changes existing behavior.

  • added ema definition to q.k, see http://code.kx.com/wiki/Reference/ema

Fixes and improvements

  • tls connection status now reported via .z.e, e.g.

    q)0N!h".z.e";
    `CIPHER`PROTOCOL!`AES128-GCM-SHA256`TLSv1.2
  • tweaked .Q.hg to process directory correctly. e.g.

    q).Q.hg`$":http://scipy-cookbook.readthedocs.io/_downloads/bezdekIris.data.txt"

2016.05.12

New

  • added tls support, see http://code.kx.com/wiki/Cookbook/SSL

  • added .Q.hg, http get. e.g.

    q).Q.hg`$":https://kx.com/index.php"

Fixes and improvements

  • reduced dependency on /dev/shm for decompression for more recent linux kernels (3.17+).

  • added single random permutation for 0N?x, which was either throwing 'g0 or entering an infitine loop. e.g.

    q)0N?10
  • lists were not collapsing for table[columnname]. e.g.

    q)98h=type([]a:(2#enlist`a`b`c!1 2 3))`a
  • catch self-references which could result in a seg-fault through native stack overflow. e.g.

    q)x:`x@;x 1
  • trying to serialize functions loaded from shared libraries could crash. w.g.

    q)-8!(`a;f)!0 1 / where f is a function bound from a shared library

2016.04.11

  • Some variations of select using in as the first constraint could crash, since v3.4t 2016.03.29. e.g.

    q)select from([]c:())where c in{}

2016.04.10

New

  • enhanced some error messages to provide more context info. e.g.

    q)eval(6;9i)
    'Cannot write to handle 6. OS reports: Bad file descriptor
  • added snappy (install from http://google.github.io/snappy) as a compression algorithm option #3.

    binds dynamically to snappy shared libs (windows:snappy.dll,osx:libsnappy.dylib,other:libsnappy.so.1) on system. e.g.
    q).z.zd:17 3 0;`:compressedFile set asc 100000#0xff
  • extended reshape to single dimension. e.g.

    q)0 1~enlist[2]#til 10

2016.03.29

Fixes and improvements

  • select ... where s in S, with large S and attr on s was performing poorly. e.g.

    q)t:([]s:`g#enlist`BLAH);S:-60000?`4;system"ts select from t where s in S"
  • added data integrity checks for verbs when reading a file. e.g.

    q)all@[{get`:a 1:x;0b};;{"parse"~x}]each(0xff01652c;0xff016625;0xff016706)
  • reshape extended to >2 dimensions, lhs must not contain nulls. e.g.

    q)(2 2 3#til 5)~((0 1 2;3 4 0);(1 2 3;4 0 1))
    q)(enlist("";""))~1 2 0#"a"
    q)all`domain=@[;1 2;{`$x}]each(#)@'(1 0 2;2 3 0N;0N 2 1;-1 2 3)
  • since 2015.06.09 embedded line returns in strings in csv/dsv files have been allowed.

    This is now switchable via an optional 3rd arg to the lhs list to 0:, and defaults to 0 with 2args only. e.g.
    q)("I*";",";1)0:("0,\"ab\nc\"";"1,\"def\"")

2016.03.14

New

  • rename .Q.ffs to .Q.fps, added .Q.fpn. These are pipe analogues to .Q.fs and .Q.fsn.

  • .Q.en can now handle lists of sym vectors. e.g.

    q).Q.en[`:.;([]a:`a`b`c;b:(`a`b;`c`d`e;0#`);c:0 1 2;d:`x`y`z)]

Fixes and improvements

  • bin was not matching 0n at offset 0, since 3.2 2014.07.19. e.g.

    q)0 1 2 3~0n 1 2 3 bin 0n 1 2 3
  • Fixed width parsing using 0: and 1: were not ignoring double quotes inside symbol fields, since 3.3 2015.06.09. e.g.

    q)(3#`hello;3#`$"wor\"ld")~("SS";6 6)0:3#enlist"hello wor\"ld"
  • `g attr data could be incorrect from appending an object with a g attr to an empty `g#(), leaking memory. e.g.

    q)do[1000;a:`g#100000#`a`b;b:`g#();b,:a;delete a,b from`.] / leaked memory
    q)a:`g#();b:`g#99#til 3;a,:b;delete a,b from`.;3 4 5~distinct `g#99#3+til 3 / incorrect index data
  • `g attr data was not updated for lists when a single element was amended, now drops g attr. e.g.

    q)~/[distinct each(`#;::)@'2#enlist@[`g#(1 2;3 4;1 2);1;:;5 6]]
  • Added presence of arg check to .Q.chk.

  • During partitioned select, now checks that .Q.ps exists and is a lambda; previously crashed.

  • If append to an enum target fails, it will truncate the file to the original size and throw an error. e.g.

    q)`:myenum?-10000?`8
    'myenum: No space left on device
  • Update from dict could crash instead of throwing mismatch. e.g.

    q)update a:@[a;`d;:;`e]from(enlist`a)!enlist(enlist`b)!enlist`c
  • Amend at depth was broken in multithreaded modes since 3.4t 2016.02.17.

2016.02.18

Fixes and improvements

  • Amend was broken for some cases since 3.4t 2016.02.17 causing a crash. e.g.

    q)([a:1 2 3]b:8 5 6)~.[([a:1 2 3];b:4 5 6);(1;`b);2*]

2016.02.17

New

  • Allow .Q.MAP[] to be used after .Q.bv[].

  • Mappable files with u,p or g attr now use zero rather than random values for unused padding bytes.

  • Added .Q.ffs to q.k. This behaves as .Q.fs but for pipes. e.g.

    $mkfifo f;unzip -p asd.zip asd.csv > f
    q).Q.ffs[{0N!("SII";",")0:x}]`:f
  • Allow indexing past depth of 2 for mix of dict/tables. e.g.

    q)dd:`k1`k2!([]foo:1 2;bar:(`a`b!3 4;`a`b!5 6));3~dd . `k1`bar`a;.[dd;`k1`bar`a;:;7]

2016.02.02

New

  • Certain mappable types can now be updated in situ, without requiring a rewrite of the whole file. e.g.

    q)`:file set til 10;@[`:file;2 4 6;:;10 20 30];get`:file
    The file must have the following properties: not compressed, no attribute, already exists, mappable flat vector, not an enum.

Fixes and improvements

  • ipc with different endian systems was broken since 2016.01.19, causing badMsg errors.

  • Saving mappable data could have stored an incorrect ref count in the header,

    causing a memory leak later when reading, since v3.4t 2015.12.13. Ref counts can be checked with
    q){$[(0xfe<>x 0)|" ">(x:read1 x)1;0b;any x$[" "=x 1;4;4+8 xbar 5+x?0x00]+til 4]}`:filename
    If this returns 1b, you should use this release to load and re-save your file.

2016.01.31

New

  • Added async broadcast as -25!(handles;msg), serializes msg once, queuing it as async msg to each handle.

  • parse (-5!x) can now handle k in addition to q code. e.g.

    q)parse each("til 10";"q)til 10";"k)!10";"q)k)!10")
  • extend a select optimisation to include npz types and >= <=. Conditions are column is called "time",

    with constraint >,<,>= or <= where 'time' is of type time,datetime,timespan,timestamp and has attr `s, and the RHS of op evaluates to an atom. e.g.
    q)n:5000000;t:([] time:`s#`timespan$til n;sym:n?`3);system"t:10 select count i from t where time <= 0D00:00:00.2"

Fixes and improvements

  • continously throwing 'close for http posts where multiple reads were necessary and connection was closed by client before all content received.

  • websockets was broken since v.3.4t 2016.01.19.

  • websockets client mode was sending close messages with an unmasked payload.

2016.01.19

New

  • Increased ipc limit from 2GB to 1TB.

  • added vaknk and vak to c-api to allow va_list arg. Signatures are

    K vaknk(I n,va_list a)
    K vak(I i,S s,va_list a)

Fixes and improvements

  • bin with lhs of table with `g#() could cause a crash, since 3.2. e.g.

    q)n:1000000;([]`g#();0)bin([]n?`3;n#0)
  • .z.w was sometimes incorrect for slave threads inside peach, affecting access control. e.g.

    q)hopen[5001]"{.z.w}peach 0 1"
  • .h.xd was not escaping & for enums

2015.12.13

New

  • Extended vs functionality to integer vs integer.

    q)192 168 161 1~256 vs -1062690559i;{x~10 vs 10 sv x}1 2 3 4
  • Improved performance of indexing J by boolean,byte and char. e.g.

    q)b:10000000?0b;system"ts:10 1 -1 b"
  • Extended .Q.bv to fill per table per segment in segmented dbs.

Fixes and improvements

  • writing the same object to multiple files concurrently could cause a crash; e.g.

    q){[x;y](hsym`$string y)set x}[0 1]peach til 100;
  • directory listings were not sorted on windows; this could stop splayed tables loading on some filesystems.

2015.11.20

New

  • allow \n inside strings for tokenize/parse. e.g.

    q)7~(eval parse"{x+:y;\nx}"). 3 4
  • improved performance of .Q.bv[]

  • .Q.bv[] allows tables to be missing from the last partition. e.g.

    q)`:2015.01.01/t/ set t:([]10?10);`:2015.01.03/t/ set t;`:2015.01.02/t2/ set t;.Q.bv[];select from t2
  • .Q.dpft now writes sym file once; previously rewrote when applying `p attr.

  • Improved performance of .Q.dpft for tables which have `g attr on sym column.

Fixes and improvements

  • was crashing when sym interning space exhausted (approx. 1.4 billion), now exits with error "too many syms".

  • blocked avg of symbols inside select. e.g.

    q)@[value;"select avg x by i from ([]`a`b);0b";{x~"type"}]
  • on disk sort, and -23!x could crash for compressed enums. e.g.

    q).z.zd:17 1 0;`:x set `sym!2129916#0i;-23!get`:x;hdel`:x;1b
  • rollback 2015.09.25 change of mod,xbar due some incompatibilies; instead improved performance of div.

  • div was incorrect for negative divisors. e.g.

    q)-2=10 div -5

2015.09.25

New

  • check ipc header for negative length, and route bad ipc header bytes to .z.bm callback.

  • improve performance of mod,xbar with _%.

  • ipc can now use unix domain sockets on unix systems. Setting the listening port with cmd line -p 5000 or via the q cmd prompt \p 5000 now also creates a UDS on /tmp/kx.5000. Local clients may connect via hopen`unix:5000.

  • kdb+ can now read from named pipes on unix. read1 is blocking, and returns 0#0x at EOF. e.g.

    q)system"mkfifo somefifo";h:hopen`fifo:somefifo;system"ls -al";0N!read1 h;hclose h