You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flink.apache.org by ja...@apache.org on 2019/12/24 02:58:01 UTC

[flink] 02/02: [FLINK-15243][table][docs] Fix documentation about how to set line feed as delimiter for csv format

This is an automated email from the ASF dual-hosted git repository.

jark pushed a commit to branch release-1.10
in repository https://gitbox.apache.org/repos/asf/flink.git

commit 3b39586a296f9a8d35d5d365c2026864f1d5ff13
Author: JingsongLi <lz...@aliyun.com>
AuthorDate: Mon Dec 23 16:36:03 2019 +0800

    [FLINK-15243][table][docs] Fix documentation about how to set line feed as delimiter for csv format
    
    This closes #10661
---
 docs/dev/table/connect.md    | 11 ++++++++---
 docs/dev/table/connect.zh.md | 11 ++++++++---
 2 files changed, 16 insertions(+), 6 deletions(-)

diff --git a/docs/dev/table/connect.md b/docs/dev/table/connect.md
index f4c8e39..fac2692 100644
--- a/docs/dev/table/connect.md
+++ b/docs/dev/table/connect.md
@@ -1364,8 +1364,11 @@ CREATE TABLE MyUserTable (
   'format.fields.1.data-type' = 'TIMESTAMP(3)',
 
   'format.field-delimiter' = ';',         -- optional: field delimiter character (',' by default)
-  'format.line-delimiter' = '\r\n',       -- optional: line delimiter ("\n" by default; otherwise
-                                          -- "\r" or "\r\n" are allowed)
+  'format.line-delimiter' = U&'\000D\000A',  -- optional: line delimiter ("\n" by default; otherwise
+                                             -- "\r" or "\r\n" are allowed), unicode is supported if the delimiter
+                                             -- is an invisible special character,
+                                             -- e.g. U&'\000D' is the unicode representation of carriage return "\r"
+                                             -- e.g. U&'\000A' is the unicode representation of line feed "\n"
   'format.quote-character' = '''',        -- optional: quote character for enclosing field values ('"' by default)
   'format.allow-comments' = 'true',       -- optional: ignores comment lines that start with "#"
                                           -- (disabled by default);
@@ -1857,7 +1860,9 @@ CREATE TABLE MyUserTable (
   'format.fields.1.data-type' = 'TIMESTAMP(3)',
 
   'format.field-delimiter' = ',',         -- optional: string delimiter "," by default
-  'format.line-delimiter' = '\n',         -- optional: string delimiter "\n" by default
+  'format.line-delimiter' = U&'\000A',    -- optional: string delimiter line feed by default, 
+                                          -- unicode is supported if the delimiter is an invisible special character, 
+                                          -- e.g. U&'\000A' is the unicode representation of line feed "\n"
   'format.quote-character' = '"',         -- optional: single character for string values, empty by default
   'format.comment-prefix' = '#',          -- optional: string to indicate comments, empty by default
   'format.ignore-first-line' = 'false',   -- optional: boolean flag to ignore the first line, by default it is not skipped
diff --git a/docs/dev/table/connect.zh.md b/docs/dev/table/connect.zh.md
index f4c8e39..fac2692 100644
--- a/docs/dev/table/connect.zh.md
+++ b/docs/dev/table/connect.zh.md
@@ -1364,8 +1364,11 @@ CREATE TABLE MyUserTable (
   'format.fields.1.data-type' = 'TIMESTAMP(3)',
 
   'format.field-delimiter' = ';',         -- optional: field delimiter character (',' by default)
-  'format.line-delimiter' = '\r\n',       -- optional: line delimiter ("\n" by default; otherwise
-                                          -- "\r" or "\r\n" are allowed)
+  'format.line-delimiter' = U&'\000D\000A',  -- optional: line delimiter ("\n" by default; otherwise
+                                             -- "\r" or "\r\n" are allowed), unicode is supported if the delimiter
+                                             -- is an invisible special character,
+                                             -- e.g. U&'\000D' is the unicode representation of carriage return "\r"
+                                             -- e.g. U&'\000A' is the unicode representation of line feed "\n"
   'format.quote-character' = '''',        -- optional: quote character for enclosing field values ('"' by default)
   'format.allow-comments' = 'true',       -- optional: ignores comment lines that start with "#"
                                           -- (disabled by default);
@@ -1857,7 +1860,9 @@ CREATE TABLE MyUserTable (
   'format.fields.1.data-type' = 'TIMESTAMP(3)',
 
   'format.field-delimiter' = ',',         -- optional: string delimiter "," by default
-  'format.line-delimiter' = '\n',         -- optional: string delimiter "\n" by default
+  'format.line-delimiter' = U&'\000A',    -- optional: string delimiter line feed by default, 
+                                          -- unicode is supported if the delimiter is an invisible special character, 
+                                          -- e.g. U&'\000A' is the unicode representation of line feed "\n"
   'format.quote-character' = '"',         -- optional: single character for string values, empty by default
   'format.comment-prefix' = '#',          -- optional: string to indicate comments, empty by default
   'format.ignore-first-line' = 'false',   -- optional: boolean flag to ignore the first line, by default it is not skipped