# tmux_query:limit/2

- **Package:** libtmux_erlang
- **Language:** Erlang
- **Kind:** function
- **Source:** https://github.com/libtmux/libtmux-erlang/blob/d1b6308440cf9eb8f6647e7ae434bce60e849368/apps/libtmux_erlang/src/tmux_query.erl#L172
- **Page:** https://libtmux.org/en/erlang/latest/reference/tmux_query-limit-2/

```
limit/2
-spec limit(0..65536, t()) -> t().
```

Set a final result limit from 0 through 65536, applied after residual filtering and identity handling. It is not a candidate-fetch limit. Performs no I/O; invalid counts raise bad_query_limit.

## Parameters

- `Count` (`0..65536`)
- `Query` (`t()`)
