Back to Clickhouse

One

docs/en/interfaces/formats/One.md

26.4.1.1-new1008 B
Original Source
InputOutputAlias

Description {#description}

The One format is a special input format that doesn't read any data from file, and returns only one row with column of type UInt8, name dummy and value 0 (like the system.one table). Can be used with virtual columns _file/_path to list all files without reading actual data.

Example usage {#example-usage}

Example:

sql
SELECT _file FROM file('path/to/files/data*', One);
text
┌─_file────┐
│ data.csv │
└──────────┘
┌─_file──────┐
│ data.jsonl │
└────────────┘
┌─_file────┐
│ data.tsv │
└──────────┘
┌─_file────────┐
│ data.parquet │
└──────────────┘

Format settings {#format-settings}