Skip to content

Commit 426acda

Browse files
committed
Fix documentation for format settings
1 parent e10665a commit 426acda

File tree

1 file changed

+22
-34
lines changed

1 file changed

+22
-34
lines changed

src/Core/FormatFactorySettings.h

Lines changed: 22 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,10 @@ Ignore extra columns in TSV input (if file has more columns than expected) and t
270270
Ignore extra columns in CustomSeparated input (if file has more columns than expected) and treat missing fields in CustomSeparated input as default values
271271
)", 0) \
272272
DECLARE(Bool, input_format_json_compact_allow_variable_number_of_columns, false, R"(
273-
Ignore extra columns in JSONCompact(EachRow) input (if file has more columns than expected) and treat missing fields in JSONCompact(EachRow) input as default values
273+
Allow variable number of columns in rows in JSONCompact/JSONCompactEachRow input formats.
274+
Ignore extra columns in rows with more columns than expected and treat missing columns as default values.
275+
276+
Disabled by default.
274277
)", 0) \
275278
DECLARE(Bool, input_format_tsv_detect_header, true, R"(
276279
Automatically detect header with names and types in TSV format
@@ -491,7 +494,12 @@ When enabled, during parsing JSON object into JSON type duplicated paths will be
491494
Maximum depth of a field in JSON. This is not a strict limit, it does not have to be applied precisely.
492495
)", 0) \
493496
DECLARE(Bool, input_format_json_empty_as_default, false, R"(
494-
Treat empty fields in JSON input as default values.
497+
When enabled, replace empty input fields in JSON with default values. For complex default expressions `input_format_defaults_for_omitted_fields` must be enabled too.
498+
499+
Possible values:
500+
501+
+ 0Disable.
502+
+ 1Enable.
495503
)", 0) \
496504
DECLARE(Bool, input_format_try_infer_integers, true, R"(
497505
If enabled, ClickHouse will try to infer integers instead of floats in schema inference for text formats. If all numbers in the column from input data are integers, the result type will be `Int64`, if at least one number is float, the result type will be `Float64`.
@@ -515,7 +523,18 @@ When input_format_try_infer_datetimes is enabled, infer only DateTime64 but not
515523
Try to infer floats in exponential notation while schema inference in text formats (except JSON, where exponent numbers are always inferred)
516524
)", 0) \
517525
DECLARE(Bool, output_format_markdown_escape_special_characters, false, R"(
518-
Escape special characters in Markdown
526+
When enabled, escape special characters in Markdown.
527+
528+
[Common Mark](https://spec.commonmark.org/0.30/#example-12) defines the following special characters that can be escaped by \:
529+
530+
```
531+
! " # $ % & ' ( ) * + , - . / : ; < = > ? @ [ \ ] ^ _ ` { | } ~
532+
```
533+
534+
Possible values:
535+
536+
+ 0Disable.
537+
+ 1Enable.
519538
)", 0) \
520539
DECLARE(Bool, input_format_protobuf_flatten_google_wrappers, false, R"(
521540
Enable Google wrappers for regular non-nested columns, e.g. google.protobuf.StringValue 'str' for String column 'str'. For Nullable columns empty wrappers are recognized as defaults, and missing as nulls
@@ -862,37 +881,6 @@ Enabled by default.
862881
DECLARE(String, format_json_object_each_row_column_for_object_name, "", R"(
863882
The name of column that will be used for storing/writing object names in [JSONObjectEachRow](/interfaces/formats/JSONObjectEachRow) format.
864883
Column type should be String. If value is empty, default names `row_{i}`will be used for object names.
865-
866-
### input_format_json_compact_allow_variable_number_of_columns {#input_format_json_compact_allow_variable_number_of_columns}
867-
868-
Allow variable number of columns in rows in JSONCompact/JSONCompactEachRow input formats.
869-
Ignore extra columns in rows with more columns than expected and treat missing columns as default values.
870-
871-
Disabled by default.
872-
873-
### output_format_markdown_escape_special_characters {#output_format_markdown_escape_special_characters}
874-
875-
When enabled, escape special characters in Markdown.
876-
877-
[Common Mark](https://spec.commonmark.org/0.30/#example-12) defines the following special characters that can be escaped by \:
878-
879-
```
880-
! " # $ % & ' ( ) * + , - . / : ; < = > ? @ [ \ ] ^ _ ` { | } ~
881-
```
882-
883-
Possible values:
884-
885-
+ 0Disable.
886-
+ 1Enable.
887-
888-
### input_format_json_empty_as_default {#input_format_json_empty_as_default}
889-
890-
When enabled, replace empty input fields in JSON with default values. For complex default expressions `input_format_defaults_for_omitted_fields` must be enabled too.
891-
892-
Possible values:
893-
894-
+ 0Disable.
895-
+ 1Enable.
896884
)", 0) \
897885
\
898886
DECLARE(UInt64, output_format_pretty_max_rows, 1000, R"(

0 commit comments

Comments
 (0)