# GET, EXIST, TYPE, and SELECT

This page covers the ToriiDB commands that read a single key and the command that switches the current database.

## GET, EXIST, TYPE

```text
GET <key>
EXIST <key>
TYPE <key>
```

Expired and missing keys behave the same: `(nil)` or `(integer) 0`.

## SELECT

```text
SELECT <db>
```

`error: db index must be an integer` or `error: invalid db index: <n> (0-15)` on bad input. The prompt `toriidb[N]>` shows the current index.

## Related Pages

- [Command Summary](/cli-reference)
- [JSON Documents](/json-documents)
- [Core Concepts](/core-concepts)
