# Tables

> Structured records you edit like a spreadsheet, and agents read and write with SQL.

A table is rows under typed columns. **File › New Table** makes one. Tables are
off until you turn on `tables` in [Features](https://cydonia.sh/docs/general/features.md). A
project's tables are kept in one SQLite database, `.cydonia/data.db`.

## Columns

| Type | Holds |
| --- | --- |
| `text` | Text; **Wrap text** lets a long value run onto more lines |
| `number` | A number, shown at the **Decimal places** you set |
| `date` | A date, shown as `YYYY-MM-DD` or `Month D, YYYY` |
| `check` | A tick box |
| `url` | A web address you can click |
| `select` | One of the choices you set with **Edit options** |

A column's header opens its menu: rename it, change its type, sort by it or
clear the sort, or delete it. Changing a column's type keeps its values. Drag a
column's edge to resize it, and drag a row's handle to move it. Column order,
widths and row order are kept with the table. The headers stay in view while
you scroll, and a wide table scrolls sideways.

## Editing

Enter edits the selected cell, and Enter again saves it; Esc puts the edit
away. The arrow keys and Tab move between cells, and Shift with an arrow
extends the selection, as does dragging over cells.

⌘C copies the selected cells and ⌘V pastes a block of them in from the
selected cell; ⌘Z takes back a paste. A block that does not fit in the table is
refused.

## Exporting

**Export as XLSX** in a table's menu writes it as a workbook for Excel, Numbers
or Google Sheets: one sheet named after the table, its header row bold and
frozen, the columns in their order and widths, and the rows in the order the
table is sorted in. Each cell keeps its type: a number with the column's decimal
places, a date as a date, a checkbox as TRUE or FALSE, a URL as a link, and a
choice as its text with the column's options to pick from.

## Agents

Agents work tables through the `table_*` tools: list and create them, add,
rename, retype or delete columns, insert rows and write cells by row id, and
query any of the project's tables with read-only SQL — see
[MCP](https://cydonia.sh/docs/agents/mcp.md). Deleting a table, a column or rows needs the MCP
server's `delete` switch. `project_read_entry` on a table answers its first 200
rows and the total. Tables carry no labels.
