Skip to content

Dictionaries and tables

Duplicate keys or columns

Avoid duplicating keys in a dictionary or (column names in a) table.

Q does not reject duplicate keys, but operations on dictionaries and tables with duplicate keys are undefined.

! Dict

Make a dictionary from two lists

group

Group table entries by key values, return a dictionary

ungroup

Normalize a table of same-length lists

xasc

Sort a table in ascending order

xcol

Rename table columns

xcols

Re-order table columns

xdesc

Sort a table in descending order

xgroup

Group a table by values in selected columns

xkey

Set specified columns as primary keys of a table