# Reading tables out of a file

A spreadsheet is read as values, row by row and sheet by sheet. A CSV or TSV is read as delimited rows. What survives is the grid of values and the headers you gave it. What does not survive is the formula behind a cell, the formatting on it, anything drawn on top of the sheet, and any type you believed a column had but never declared.

- **Status:** Available
- **Audience:** both
- **In the app:** #/data
- **Last verified:** 2026-09-10
- **Canonical:** https://connectbyjbrh.com/docs/files-data/table-extraction/

## What is preserved

- The values, cell by cell, as the sheet evaluates them at the moment it is read.
- The row and column structure, so a question about the third column has an answer.
- Header names, when the first row is one — they are what makes a column answerable by name rather than by position.
- Sheet boundaries in an XLSX. Sheets are read one at a time and are not silently concatenated.

That set is deliberately small, and it is the set a question can be asked against. 'How many rows have a blank contact column' is answerable from it. 'Which cells are highlighted in yellow' is not, because colour is not in it.

## What is lost, and why

| Lost | What arrives instead | Why it matters |
|---|---|---|
| Formulas | The value the formula produced | A stale cached value in a file that was not recalculated arrives as though it were current |
| Formatting | Nothing | Meaning carried only by colour or bold is invisible; put it in a column |
| Charts, images and shapes | Nothing | A chart is a picture of data, and the data behind it is in the cells anyway |
| Merged cells | Values in the positions the file stores them | A merged header can leave neighbouring columns looking unnamed |
| Implied types | The value as stored | A code with leading zeros, or a date the spreadsheet had already reinterpreted, arrives as whatever it had become |

> **Careful** The first and last rows of that table cause most real-world surprises. A spreadsheet showing you a recalculated figure may store an older one, and a reference number that a spreadsheet application decided was a number lost its leading zeros long before Connect ever saw the file.

## Delimited files have their own habits

CSV and TSV are simpler and fail differently. Everything in them begins as characters, so a column of dates is a column of date-shaped strings until something decides otherwise. Quoting matters: a field containing the delimiter must be quoted, and a file that quotes inconsistently produces rows of the wrong width.

**A row with too many columns** — Almost always an unquoted delimiter inside a value — a comma in an address, in a comma-separated file.
**Everything in one column** — The wrong delimiter. A file saved as TSV and named `.csv` reads as one wide column.
**A first row that is not a header** — Columns are then answerable only by position, and the real header sits in the data as an ordinary row.
**Trailing blank rows** — Read as rows. A sheet dragged down further than its data produces empty records if it is imported rather than asked about.

When the destination is records rather than a question, these become dropped or malformed rows at import time. [Some imported rows are missing](/docs/troubleshooting/import-rows-dropped/) is the page for that, and it is worth reading before a large import rather than after one.

## Asking about a sheet versus importing it

These are different operations with different consequences and it is worth being deliberate about which you want. Asking is read-only: the sheet stays a file, nothing in the workspace changes, and the answer cites the file. Importing creates and updates records, which is a change to the business's data and goes through the services that own those records.

After an import, the spreadsheet is not the source of anything. The records are, and editing the original file afterwards changes nothing — while re-importing an older copy over later work is one of the few genuinely destructive things a person can do here quickly. [Importing and exporting](/docs/files-data/data-import-export/) covers the safeguards.

## Questions

### Does Connect recalculate my formulas?

No. It reads the values the file stores. A spreadsheet saved without recalculating carries older values, and those are what arrive — so recalculate and save before uploading anything whose figures depend on formulas.

### Can it read every sheet in a workbook at once?

Sheets are read one at a time. A question that spans two sheets is two reads and a comparison, and naming the sheet you mean avoids a confident answer drawn from the wrong one.

### Will a table inside a Word document be read as rows and columns?

No. A table in a DOCX comes through as words in sequence, because that is how the format stores it. For structure, send the data as XLSX or CSV.

## Related

- [File formats Connect reads](https://connectbyjbrh.com/docs/files-data/supported-formats/)
- [Reading text out of a document](https://connectbyjbrh.com/docs/files-data/text-extraction/)
- [Importing and exporting](https://connectbyjbrh.com/docs/files-data/data-import-export/)
- [Some imported rows are missing](https://connectbyjbrh.com/docs/troubleshooting/import-rows-dropped/)
- [A spreadsheet view that is not a second database](https://connectbyjbrh.com/research/grid-over-services/)

## What this page is based on

- `docs-source/sources/GENERAL.md` §9 — XLSX, CSV/TSV readers and the grid over 13 sheets
- Connect capability registry (docs-source/facts.py) — `file_workspace`, `data_workspace`
- `backend/app/file_formats.py`, `data_workspace.py` — extraction and the record services
