custom_separated_with_names
Description
Custom separated rows with a required first record of column names. Header names are literal text, including with raw escaping. Input matches names unless custom_separated_match_names is disabled.
Input and output. Select it with FORMAT custom_separated_with_names. Names ignore ASCII case; use the snake_case name shown here.
The first record identifies the fields, followed by value records with the configured delimiters. Header names remain literal field names even when field values use Raw escaping.
Name matching is enabled by default. Its positional mode skips name-based binding; unknown fields, omitted values and literal delimiters still follow the configured input rules.
SELECT expressions FORMAT custom_separated_with_names;
INSERT INTO table [(columns)] [SETTINGS ...] FORMAT custom_separated_with_names
<data>Example usage
SELECT CAST(7 AS Int64) AS id, 'Ada' AS name FORMAT custom_separated_with_names;id name
7 AdaFormat settings
Use a statement SETTINGS clause; these options are not persisted by SET.
| Setting | Type | Default | Meaning |
|---|---|---|---|
custom_separated_escaping |
String |
Escaped |
Field grammar: Escaped, Quoted, CSV, JSON, XML (output only), or Raw. |
custom_separated_match_names |
Bool |
1 |
Match input names to target columns ignoring ASCII case; when off, skip the names header and read in target order. |
custom_separated_result_prefix |
String |
'' |
Text before the entire input or output result. |
custom_separated_result_suffix |
String |
'' |
Text after the entire input or output result. |
custom_separated_row_prefix |
String |
'' |
Text before the first field of each input or output row. |
custom_separated_row_separator |
String |
'' |
Text between input or output rows, excluding their own prefixes and suffixes. |
custom_separated_row_suffix |
String |
\n |
Text after the last field of each input or output row. |
custom_separated_separator |
String |
\t |
Text between input or output fields; may contain multiple bytes. |
custom_separated_skip_empty_lines |
Bool |
0 |
Skip trailing CR and LF bytes after the result; one final LF is always accepted. |
custom_separated_uneven_rows |
Bool |
0 |
Give omitted input fields their SQL or native defaults and validate then skip extra fields. |
ignore_unknown_fields |
Bool |
0 |
Skip input keys and header names that match no target column instead of failing. |
snappy_mode |
String |
basic |
Read Snappy client files as basic (Hadoop blocks) or framed (standard streaming format). |