Collections
A collection row queries tabular account data — orders, positions, balances, accounts, or whatever else the connected broker declares — filtered, sorted, and capped entirely client-side against data already in memory.
Collection keyword
COLLECTION[:PARAM][:ADAPTER] [[COL, COL, ...]] [WHERE ...] [ORDER BY ...] [LIMIT:N]
ORDERS, POSITIONS, BALANCES, and ACCOUNTS are recognized everywhere — they're built into
the parser. Everything else (e.g. FILLS on Coinbase and Kalshi) is recognized because the
connected broker's adapter declares it. Which collections exist, and which columns each one has,
depends entirely on the broker — see
VectarisQL collections by broker for the full per-broker
breakdown. This is the one part of the grammar whose shape changes with what you're connected to.
:PARAM and :ADAPTER
:PARAM(optional) — a collection-specific parameter, most often an account label, e.g.POSITIONS:acct1,ORDERS:"Schwab Test". Quote it if it has spaces.:ADAPTER— the grammar reserves a second colon-delimited segment to force a specific adapter when more than one connected broker declares the same collection name. It has no effect yet: the wired collection parser only ever splits the first colon after the collection keyword, and folds everything past it — including a second colon — into:PARAMas one string.POSITIONS:acct1:Schwabtoday parses asparam = "acct1:Schwab", notparam = "acct1"with an adapter override.
Columns, WHERE, ORDER BY, LIMIT
[COL, COL, ...]projects specific columns; omit it and the collection's declared default columns are used.WHEREfilters rows; conditions join withAND/OR, evaluated left to right with no parenthesized grouping. String literals are quoted (STATUS='Filled') and are not force-uppercased —'Filled'stays exactly as typed. See the WHERE operators table for which operators apply to which column type.ORDER BYsorts by one or more columns, each with an optionalASC/DESC(defaultASC), comma-separated for multiple columns.LIMIT:Ncaps the row count to a positive integer.
Column names are matched case-insensitively and aliases resolve to the canonical column — see VectarisQL collections by broker for exact column lists per collection.
Examples
ORDERS
ORDERS:Schwab
ORDERS [SYMBOL, SIDE, QTY, STATUS]
ORDERS WHERE STATUS='Filled' ORDER BY TIME DESC
POSITIONS WHERE UNREALIZEDPNL > 0 LIMIT:20
ORDERS:"Schwab Test"
POSITIONS:acct1 [SYMBOL, QTY, UNREALIZEDPNL] WHERE UNREALIZEDPNL > 0
DataGrid is the query bar that accepts collection rows today — open a DataGrid tab and type a collection keyword into its query bar.