> ## Documentation Index
> Fetch the complete documentation index at: https://docs.e6data.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Read CSV with a header and explicit column types

> Register a temporary file view and query the selected input.

How-to guideApplies to: Unified engine deployments

Register a temporary file view and query the selected input.

## Before you start

Prepare a UTF-8 CSV file with header order\_id,amount and data rows 1,12.5 and
2,7.5. The explicit schema must match those columns.

The files must already exist under a configured local file-source root. Use the
path visible to the engine and workers, rather than a path that exists only on
your laptop. See
[file-source configuration](https://docs.e6data.com/transformation/sql/tables-and-sources.md#file-sources).

## Values to collect

* Absolute configured file path, or folder path for the filter recipe.

## Run the SQL

Replace every `<placeholder>` before running. Use unused names for the resources
below. Run the statements in order in Workbench.

```sql theme={"theme":{"light":"github-light","dark":"github-dark"}}
CREATE OR REPLACE TEMPORARY VIEW recipe_csv_header (order_id BIGINT, amount DOUBLE)
USING csv
OPTIONS (
  path '<configured-input-path>',
  header 'true',
  delimiter ','
);

SELECT * FROM recipe_csv_header LIMIT 5;
```

## Check the result

The SELECT should show the prepared order\_id and amount fields. For the two-row
examples, expect values (1, 12.5) and (2, 7.5), in any order. For a folder read,
only matching CSV inputs should contribute rows.

## Clean up

Drop the temporary view. Input files stay in place.

```sql theme={"theme":{"light":"github-light","dark":"github-dark"}}
DROP VIEW recipe_csv_header;
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.