Given the following table:
time | col1 col2 col3 ...
--------------------------------
10:53:02 | 89 89 76 ...
...
How does one select a subset of columns from this table (including the index) referenced by a list of column names i.e. cols:('col1';'col3');
Whereby the expected result would be:
time | col1 col3
----------------------
10:53:02 | 89 89
...
Thanks
cols
is not a valid variable name in KDB+, as it is already the name of a built-in function. Usually a lower casec
will suffice. In the above,cols:('col1';'col3')
would be better written asc:`col1`col2
– Thermosphere