---
title: "Excel@1"
description: "Excel@1 — one worksheet of an xlsx workbook, simple filtering, strike-through rows skipped, no driver needed"
url: "https://docs.justcat.it/reference/data-sources/providers/excel-1/"
---
# Excel@1


## Connects to

MS Excel `.xlsx` workbooks; the older `.xls` format is not supported. For full SQL over workbook data (joins, `GROUP BY`, `ORDER BY`, functions) use [Excel@2](https://docs.justcat.it/reference/data-sources/providers/excel-2/ "Excel@2"); `Excel@1` is the one that can also serve lists of definitions and honours strike-through.

The workbook may stay open in Excel while CAT runs — edit it, save it and run CAT without closing the file.

## Example


**Properties**



Name
: MyExcelData

Provider
: Excel@1

Technology
: Excel

Connection string
: ./MyData.xlsx





**YAML**


```yaml
Data sources:
- Name: MyExcelData
  Provider: Excel@1
  Technology: Excel
  Connection string: ./MyData.xlsx # file in this directory (where the project file is)
```




## Connection string

Not a connection string: **the path to one `.xlsx` file**, absolute or relative to the directory of the project file. The same slot is also accepted as `File path` — see [Data source properties](https://docs.justcat.it/reference/data-sources/properties/#connection-string "Data source properties"). The worksheet is then named in the query's `FROM` clause.


**Properties**



Name
: generated xlsx

Provider
: Excel@1

Technology
: Excel

Connection string
: T:\MySystemTests\GeneratedExcelFiles\2023.xlsx





**YAML**


```yaml
Data sources:
- Name: generated xlsx
  Provider: Excel@1
  Technology: Excel
  Connection string: "T:\\MySystemTests\\GeneratedExcelFiles\\2023.xlsx"
```




Queries then read `SELECT * FROM [Sheet1]`, `SELECT * FROM [Sheet2]` and so on.

## Settings

| Setting | Default | Meaning |
|---|---|---|
| `Skip striked through` | `true` | A row that has at least one cell with strike-through text is ignored — as if the row did not exist. Set to `false` to read such rows like any other. |

> **🐱:** While this might seem useless for data testing, it is very handy in one case — when test definitions are loaded from MS Excel. Format the rows you want to ignore for a while with strike-through and CAT pretends it does not see them.



## Query

A SQL statement, even though no database is involved — CAT needs it to know which worksheet to read, because the connection string names only the file. Only these clauses are supported:

| SQL clause | Notes |
|---|---|
| `SELECT` | Either `*` or a comma-separated list of column names in square brackets. The columns may be listed in a different order than in the worksheet. |
| `FROM` | Just the name of an existing worksheet in the workbook given by the connection string. Square brackets around the sheet name are recommended. No joins. |
| `WHERE` | Only `[Column name] = 'something'`; several conditions joined with `AND`. No functions, no `OR`, no brackets — simple filtering on one or more columns. |

```sql
SELECT  [Last Name], [First name]
FROM    [Sheet1]
WHERE   [First Name] = 'Helena' AND [ID] = 2
```

## Prerequisites

None. The driver ships with CAT. Windows; on Linux it has no extra dependencies and is expected to work, but it has not been tested there.

## Limitations

* The first row of the worksheet holds the column names; reading stops at the first row that is empty in every column.

## Serving test and data source definitions

`Excel@1` can also serve [lists](https://docs.justcat.it/reference/project-file/lists/ "Lists") of definitions: a worksheet whose header row carries the property names of a [test](https://docs.justcat.it/reference/tests/properties/ "Test properties"), [data source](https://docs.justcat.it/reference/data-sources/properties/ "Data source properties") or [query](https://docs.justcat.it/reference/queries/properties/ "Query properties") definition, one definition per row; the query's `FROM` names the worksheet. Rows struck through are skipped — that is what the `Skip striked through` setting is for. [Organize a growing test base](https://docs.justcat.it/how-to-guides/organize-and-run-tests/organize-test-definitions/ "Organize a growing test base") shows a workbook in use.

## Related

* [Technologies](https://docs.justcat.it/reference/data-sources/technologies/ "Technologies") — MS Excel file and the provider behind it.
* [Excel@2](https://docs.justcat.it/reference/data-sources/providers/excel-2/ "Excel@2") — full SQL over workbooks, no driver either.
* [Organize test definitions](https://docs.justcat.it/how-to-guides/organize-and-run-tests/organize-test-definitions/ "Organize test definitions") — keeping tests in a workbook served by `Excel@1`.

