ClickHouse/clickhouse-docs-embeddings huggingface dataset:
title_wip

[Edit this page](https://github.com/ClickHouse/ClickHouse/tree/master/docs/en/interfaces/formats/LineAsString/LineAsStringWithNames.md)

|  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- |
| Input Output Alias|  |  |  | | --- | --- | --- | | ✗ ✔  | | | | | |

## Description[​](#description "Direct link to Description")

The `LineAsStringWithNames` format is similar to the [`LineAsString`](/docs/interfaces/formats/LineAsString) format but prints the header row with column names.

## Example usage[​](#example-usage "Direct link to Example usage")

```
CREATE TABLE example (
    name String,
    value Int32
)
ENGINE = Memory;

INSERT INTO example VALUES ('John', 30), ('Jane', 25), ('Peter', 35);

SELECT * FROM example FORMAT LineAsStringWithNames;
```

```
name    value
John    30
Jane    25
Peter    35
```

## Format settings[​](#format-settings "Direct link to Format settings")

- [Description](#description)- [Example usage](#example-usage)- [Format settings](#format-settings)

Was this page helpful?
title_wip

[Edit this page](https://github.com/ClickHouse/ClickHouse/tree/master/docs/en/interfaces/formats/LineAsString/LineAsStringWithNamesAndTypes.md)

|  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- |
| Input Output Alias|  |  |  | | --- | --- | --- | | ✗ ✔  | | | | | |

## Description[​](#description "Direct link to Description")

The `LineAsStringWithNames` format is similar to the [`LineAsString`](/docs/interfaces/formats/LineAsString) format
but prints two header rows: one with column names, the other with types.

## Example usage[​](#example-usage "Direct link to Example usage")

```
CREATE TABLE example (
    name String,
    value Int32
)
ENGINE = Memory;

INSERT INTO example VALUES ('John', 30), ('Jane', 25), ('Peter', 35);

SELECT * FROM example FORMAT LineAsStringWithNamesAndTypes;
```

```
name    value
String    Int32
John    30
Jane    25
Peter    35
```

## Format settings[​](#format-settings "Direct link to Format settings")

- [Description](#description)- [Example usage](#example-usage)- [Format settings](#format-settings)

Was this page helpful?
title_wip

[Edit this page](https://github.com/ClickHouse/ClickHouse/tree/master/docs/en/interfaces/formats/Markdown.md)

|  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- |
| Input Output Alias|  |  |  | | --- | --- | --- | | ✗ ✔ `MD` | | | | | |

## Description[​](#description "Direct link to Description")

You can export results using [Markdown](https://en.wikipedia.org/wiki/Markdown) format to generate output ready to be pasted into your `.md` files:

The markdown table will be generated automatically and can be used on markdown-enabled platforms, like Github. This format is used only for output.

## Example usage[​](#example-usage "Direct link to Example usage")

```
SELECT
    number,
    number * 2
FROM numbers(5)
FORMAT Markdown
```

```
| number | multiply(number, 2) |
|-:|-:|
| 0 | 0 |
| 1 | 2 |
| 2 | 4 |
| 3 | 6 |
| 4 | 8 |
```

## Format settings[​](#format-settings "Direct link to Format settings")

- [Description](#description)- [Example usage](#example-usage)- [Format settings](#format-settings)

Was this page helpful?
title_wip

[Edit this page](https://github.com/ClickHouse/ClickHouse/tree/master/docs/en/interfaces/formats/MySQLWire.md)

## Description[​](#description "Direct link to Description")

## Example usage[​](#example-usage "Direct link to Example usage")

## Format settings[​](#format-settings "Direct link to Format settings")

- [Description](#description)- [Example usage](#example-usage)- [Format settings](#format-settings)

Was this page helpful?
title_wip

[Edit this page](https://github.com/ClickHouse/ClickHouse/tree/master/docs/en/interfaces/formats/ODBCDriver2.md)

## Description[​](#description "Direct link to Description")

## Example usage[​](#example-usage "Direct link to Example usage")

## Format settings[​](#format-settings "Direct link to Format settings")

- [Description](#description)- [Example usage](#example-usage)- [Format settings](#format-settings)

Was this page helpful?
title_wip

To exchange data with Hadoop, you can use [HDFS table engine](/docs/engines/table-engines/integrations/hdfs).

- [Description](#description)- [Data types matching](#data-types-matching-orc)- [Example usage](#example-usage)
      - [Inserting data](#inserting-data)- [Reading data](#reading-data)- [Format settings](#format-settings)

Was this page helpful?
title_wip

[Edit this page](https://github.com/ClickHouse/ClickHouse/tree/master/docs/en/interfaces/formats/One.md)

|  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- |
| Input Output Alias|  |  |  | | --- | --- | --- | | ✔ ✗  | | | | | |

## Description[​](#description "Direct link to 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`](/docs/sql-reference/data-types/int-uint), 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 "Direct link to Example usage")

Example:

```
SELECT _file FROM file('path/to/files/data*', One);
```

```
┌─_file────┐
│ data.csv │
└──────────┘
┌─_file──────┐
│ data.jsonl │
└────────────┘
┌─_file────┐
│ data.tsv │
└──────────┘
┌─_file────────┐
│ data.parquet │
└──────────────┘
```

## Format settings[​](#format-settings "Direct link to Format settings")

- [Description](#description)- [Example usage](#example-usage)- [Format settings](#format-settings)

Was this page helpful?
title_wip

## Example usage[​](#example-usage "Direct link to Example usage")

### Inserting data[​](#inserting-data "Direct link to Inserting data")

Using a Parquet file with the following data, named as `football.parquet`:

```
    ┌───────date─┬─season─┬─home_team─────────────┬─away_team───────────┬─home_team_goals─┬─away_team_goals─┐
 1. │ 2022-04-30 │   2021 │ Sutton United         │ Bradford City       │               1 │               4 │
 2. │ 2022-04-30 │   2021 │ Swindon Town          │ Barrow              │               2 │               1 │
 3. │ 2022-04-30 │   2021 │ Tranmere Rovers       │ Oldham Athletic     │               2 │               0 │
 4. │ 2022-05-02 │   2021 │ Port Vale             │ Newport County      │               1 │               2 │
 5. │ 2022-05-02 │   2021 │ Salford City          │ Mansfield Town      │               2 │               2 │
 6. │ 2022-05-07 │   2021 │ Barrow                │ Northampton Town    │               1 │               3 │
 7. │ 2022-05-07 │   2021 │ Bradford City         │ Carlisle United     │               2 │               0 │
 8. │ 2022-05-07 │   2021 │ Bristol Rovers        │ Scunthorpe United   │               7 │               0 │
 9. │ 2022-05-07 │   2021 │ Exeter City           │ Port Vale           │               0 │               1 │
10. │ 2022-05-07 │   2021 │ Harrogate Town A.F.C. │ Sutton United       │               0 │               2 │
11. │ 2022-05-07 │   2021 │ Hartlepool United     │ Colchester United   │               0 │               2 │
12. │ 2022-05-07 │   2021 │ Leyton Orient         │ Tranmere Rovers     │               0 │               1 │
13. │ 2022-05-07 │   2021 │ Mansfield Town        │ Forest Green Rovers │               2 │               2 │
14. │ 2022-05-07 │   2021 │ Newport County        │ Rochdale            │               0 │               2 │
15. │ 2022-05-07 │   2021 │ Oldham Athletic       │ Crawley Town        │               3 │               3 │
16. │ 2022-05-07 │   2021 │ Stevenage Borough     │ Salford City        │               4 │               2 │
17. │ 2022-05-07 │   2021 │ Walsall               │ Swindon Town        │               0 │               3 │
    └────────────┴────────┴───────────────────────┴─────────────────────┴─────────────────┴─────────────────┘
```

Insert the data:

```
INSERT INTO football FROM INFILE 'football.parquet' FORMAT Parquet;
```

### Reading data[​](#reading-data "Direct link to Reading data")

Read data using the `Parquet` format:

```
SELECT *
FROM football
INTO OUTFILE 'football.parquet'
FORMAT Parquet
```

Tip

Parquet is a binary format that does not display in a human-readable form on the terminal. Use the `INTO OUTFILE` to output Parquet files.

To exchange data with Hadoop, you can use the [`HDFS table engine`](/docs/engines/table-engines/integrations/hdfs).

## Format settings[​](#format-settings "Direct link to Format settings")
title_wip

[Edit this page](https://github.com/ClickHouse/ClickHouse/tree/master/docs/en/interfaces/formats/PostgreSQLWire.md)

## Description[​](#description "Direct link to Description")

## Example usage[​](#example-usage "Direct link to Example usage")

## Format settings[​](#format-settings "Direct link to Format settings")

- [Description](#description)- [Example usage](#example-usage)- [Format settings](#format-settings)

Was this page helpful?
title_wip

[Edit this page](https://github.com/ClickHouse/ClickHouse/tree/master/docs/en/interfaces/formats/Pretty/PrettyCompact.md)

|  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- |
| Input Output Alias|  |  |  | | --- | --- | --- | | ✗ ✔  | | | | | |

## Description[​](#description "Direct link to Description")

Differs from the [`Pretty`](/docs/interfaces/formats/Pretty) format in that the table is displayed with a grid drawn between rows.
Because of this the result is more compact.

Note

This format is used by default in the command-line client in interactive mode.

## Example usage[​](#example-usage "Direct link to Example usage")

## Format settings[​](#format-settings "Direct link to Format settings")

The following settings are common to all `Pretty` formats:

|  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
| Setting Description Default|  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  | | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | | [`output_format_pretty_max_rows`](/docs/operations/settings/formats#output_format_pretty_max_rows) Row limit for Pretty formats. `10000`| [`output_format_pretty_max_column_pad_width`](/docs/operations/settings/formats#output_format_pretty_max_column_pad_width) Maximum width to pad all values in a column in Pretty formats. `250`| [`output_format_pretty_max_value_width`](/docs/operations/settings/formats#output_format_pretty_max_value_width) Maximum width of value to display in Pretty formats. If greater - it will be cut. `10000`| [`output_format_pretty_color`](/docs/operations/settings/formats#output_format_pretty_color) Use ANSI escape sequences to paint colors in Pretty formats. `true`| [`output_format_pretty_grid_charset`](/docs/operations/settings/formats#output_format_pretty_grid_charset) Charset for printing grid borders. Available charsets: ASCII, UTF-8. `UTF-8`| [`output_format_pretty_row_numbers`](/docs/operations/settings/formats#output_format_pretty_row_numbers) Add row numbers before each row for pretty output format. `true`| [`output_format_pretty_display_footer_column_names`](/docs/operations/settings/formats#output_format_pretty_display_footer_column_names) Display column names in the footer if table contains many rows. `true`| [`output_format_pretty_display_footer_column_names_min_rows`](/docs/operations/settings/formats#output_format_pretty_display_footer_column_names_min_rows) Sets the minimum number of rows for which a footer will be displayed if [`output_format_pretty_display_footer_column_names`](/docs/operations/settings/formats#output_format_pretty_display_footer_column_names) is enabled. `50` | | | | | | | | | | | | | | | | | | | | | | | | | | |

- [Description](#description)- [Example usage](#example-usage)- [Format settings](#format-settings)

Was this page helpful?
title_wip

[Edit this page](https://github.com/ClickHouse/ClickHouse/tree/master/docs/en/interfaces/formats/Pretty/PrettyCompactMonoBlock.md)

|  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- |
| Input Output Alias|  |  |  | | --- | --- | --- | | ✗ ✔  | | | | | |

## Description[​](#description "Direct link to Description")

Differs from the [`PrettyCompact`](/docs/interfaces/formats/PrettyCompact) format in that up to `10,000` rows are buffered,
and then output as a single table, and not by [blocks](/docs/development/architecture#block).

## Example usage[​](#example-usage "Direct link to Example usage")

## Format settings[​](#format-settings "Direct link to Format settings")

The following settings are common to all `Pretty` formats:

|  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
| Setting Description Default|  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  | | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | | [`output_format_pretty_max_rows`](/docs/operations/settings/formats#output_format_pretty_max_rows) Row limit for Pretty formats. `10000`| [`output_format_pretty_max_column_pad_width`](/docs/operations/settings/formats#output_format_pretty_max_column_pad_width) Maximum width to pad all values in a column in Pretty formats. `250`| [`output_format_pretty_max_value_width`](/docs/operations/settings/formats#output_format_pretty_max_value_width) Maximum width of value to display in Pretty formats. If greater - it will be cut. `10000`| [`output_format_pretty_color`](/docs/operations/settings/formats#output_format_pretty_color) Use ANSI escape sequences to paint colors in Pretty formats. `true`| [`output_format_pretty_grid_charset`](/docs/operations/settings/formats#output_format_pretty_grid_charset) Charset for printing grid borders. Available charsets: ASCII, UTF-8. `UTF-8`| [`output_format_pretty_row_numbers`](/docs/operations/settings/formats#output_format_pretty_row_numbers) Add row numbers before each row for pretty output format. `true`| [`output_format_pretty_display_footer_column_names`](/docs/operations/settings/formats#output_format_pretty_display_footer_column_names) Display column names in the footer if table contains many rows. `true`| [`output_format_pretty_display_footer_column_names_min_rows`](/docs/operations/settings/formats#output_format_pretty_display_footer_column_names_min_rows) Sets the minimum number of rows for which a footer will be displayed if [`output_format_pretty_display_footer_column_names`](/docs/operations/settings/formats#output_format_pretty_display_footer_column_names) is enabled. `50` | | | | | | | | | | | | | | | | | | | | | | | | | | |

- [Description](#description)- [Example usage](#example-usage)- [Format settings](#format-settings)

Was this page helpful?
title_wip

[Edit this page](https://github.com/ClickHouse/ClickHouse/tree/master/docs/en/interfaces/formats/Pretty/PrettyCompactNoEscapes.md)

|  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- |
| Input Output Alias|  |  |  | | --- | --- | --- | | ✗ ✔  | | | | | |

## Description[​](#description "Direct link to Description")

Differs from the [`PrettyCompact`](/docs/interfaces/formats/PrettyCompact) format in that [ANSI-escape sequences](https://en.wikipedia.org/wiki/ANSI_escape_code) aren't used.
This is necessary for displaying the format in a browser, as well as for using the 'watch' command-line utility.

## Example usage[​](#example-usage "Direct link to Example usage")

## Format settings[​](#format-settings "Direct link to Format settings")

The following settings are common to all `Pretty` formats:

|  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
| Setting Description Default|  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  | | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | | [`output_format_pretty_max_rows`](/docs/operations/settings/formats#output_format_pretty_max_rows) Row limit for Pretty formats. `10000`| [`output_format_pretty_max_column_pad_width`](/docs/operations/settings/formats#output_format_pretty_max_column_pad_width) Maximum width to pad all values in a column in Pretty formats. `250`| [`output_format_pretty_max_value_width`](/docs/operations/settings/formats#output_format_pretty_max_value_width) Maximum width of value to display in Pretty formats. If greater - it will be cut. `10000`| [`output_format_pretty_color`](/docs/operations/settings/formats#output_format_pretty_color) Use ANSI escape sequences to paint colors in Pretty formats. `true`| [`output_format_pretty_grid_charset`](/docs/operations/settings/formats#output_format_pretty_grid_charset) Charset for printing grid borders. Available charsets: ASCII, UTF-8. `UTF-8`| [`output_format_pretty_row_numbers`](/docs/operations/settings/formats#output_format_pretty_row_numbers) Add row numbers before each row for pretty output format. `true`| [`output_format_pretty_display_footer_column_names`](/docs/operations/settings/formats#output_format_pretty_display_footer_column_names) Display column names in the footer if table contains many rows. `true`| [`output_format_pretty_display_footer_column_names_min_rows`](/docs/operations/settings/formats#output_format_pretty_display_footer_column_names_min_rows) Sets the minimum number of rows for which a footer will be displayed if [`output_format_pretty_display_footer_column_names`](/docs/operations/settings/formats#output_format_pretty_display_footer_column_names) is enabled. `50` | | | | | | | | | | | | | | | | | | | | | | | | | | |

- [Description](#description)- [Example usage](#example-usage)- [Format settings](#format-settings)

Was this page helpful?
title_wip

[Edit this page](https://github.com/ClickHouse/ClickHouse/tree/master/docs/en/interfaces/formats/Pretty/PrettyCompactNoEscapesMonoBlock.md)

|  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- |
| Input Output Alias|  |  |  | | --- | --- | --- | | ✗ ✔  | | | | | |

## Description[​](#description "Direct link to Description")

Differs from the [`PrettyCompactNoEscapes`](/docs/interfaces/formats/PrettyCompactNoEscapes) format in that up to `10,000` rows are buffered,
and then output as a single table, and not by [blocks](/docs/development/architecture#block).

## Example usage[​](#example-usage "Direct link to Example usage")

## Format settings[​](#format-settings "Direct link to Format settings")

The following settings are common to all `Pretty` formats:

|  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
| Setting Description Default|  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  | | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | | [`output_format_pretty_max_rows`](/docs/operations/settings/formats#output_format_pretty_max_rows) Row limit for Pretty formats. `10000`| [`output_format_pretty_max_column_pad_width`](/docs/operations/settings/formats#output_format_pretty_max_column_pad_width) Maximum width to pad all values in a column in Pretty formats. `250`| [`output_format_pretty_max_value_width`](/docs/operations/settings/formats#output_format_pretty_max_value_width) Maximum width of value to display in Pretty formats. If greater - it will be cut. `10000`| [`output_format_pretty_color`](/docs/operations/settings/formats#output_format_pretty_color) Use ANSI escape sequences to paint colors in Pretty formats. `true`| [`output_format_pretty_grid_charset`](/docs/operations/settings/formats#output_format_pretty_grid_charset) Charset for printing grid borders. Available charsets: ASCII, UTF-8. `UTF-8`| [`output_format_pretty_row_numbers`](/docs/operations/settings/formats#output_format_pretty_row_numbers) Add row numbers before each row for pretty output format. `true`| [`output_format_pretty_display_footer_column_names`](/docs/operations/settings/formats#output_format_pretty_display_footer_column_names) Display column names in the footer if table contains many rows. `true`| [`output_format_pretty_display_footer_column_names_min_rows`](/docs/operations/settings/formats#output_format_pretty_display_footer_column_names_min_rows) Sets the minimum number of rows for which a footer will be displayed if [`output_format_pretty_display_footer_column_names`](/docs/operations/settings/formats#output_format_pretty_display_footer_column_names) is enabled. `50` | | | | | | | | | | | | | | | | | | | | | | | | | | |

- [Description](#description)- [Example usage](#example-usage)- [Format settings](#format-settings)

Was this page helpful?