Open richardbutler opened 7 years ago
Hi @richardbutler
Just by looking at the example, it seems to me that the "only" thing that is missing is the typed.operator()
thing?
the rest should work.
Let's see how q serialises operators:
q)-8!(=;`a;1b)
0x01000000150000 00000003000000 66 08 f5 6100 ff 01
q)-8!(>;`a;1b)
0x0100000015000000000003000000 66 0a f5 6100 ff 01
q)-8!(in;`a;1b)
0x0100000015000000000003000000 66 17 f5 6100 ff 01
so the type of the operator seems to be 102 (66 hex) which is binary primitive according to code.kx.com
I can't really find a documentation about this data type. Do we have to map all the primitives? :)
= => 08
> => 0a
in => 17
On further investigation with some colleagues who know KDB far better than I do, it seems these codes will likely change from version to version. It seems that this may well break from one release to the next or, at the very least, KX don't guarantee they won't change.
I think we need some insights from KX here. Unfortunately, I have no access to the internal mailing list any more. Do you have access? Otherwise I can post to to the open source list.
Hi Michael
Have you considered how this library might support functional selects (parse trees) via its serialisation capability? For example, the Q expression:
could be expressed as something like this: