From d20441f00223a25208197e937abefefda72e2dce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B0=A2=E5=81=A5?= Date: Thu, 16 Nov 2023 13:51:43 +0800 Subject: [PATCH] [doc](Nereids) add doc for NO_BACKSLASH_ESCAPES (#26995) --- docs/en/docs/advanced/sql-mode.md | 5 +++++ docs/zh-CN/docs/advanced/sql-mode.md | 6 ++++++ 2 files changed, 11 insertions(+) diff --git a/docs/en/docs/advanced/sql-mode.md b/docs/en/docs/advanced/sql-mode.md index 4c9227f0d2..6ea368796a 100644 --- a/docs/en/docs/advanced/sql-mode.md +++ b/docs/en/docs/advanced/sql-mode.md @@ -66,6 +66,11 @@ show session variables 1. `PIPES_AS_CONCAT` In this mode, the '||' symbol is a string concatenation symbol (same as the CONCAT() function), not a synonym for the 'OR' symbol. (e.g., `'a'||'b' = 'ab'`, `1||0 = '10'`) + +2. `NO_BACKSLASH_ESCAPES` + +Enabling this mode disables the backslash character (\\) from functioning as an escape character within strings and identifiers. When this mode is enabled, the backslash is treated as a regular character without any special meaning + ## composite mode (subsequent additions) diff --git a/docs/zh-CN/docs/advanced/sql-mode.md b/docs/zh-CN/docs/advanced/sql-mode.md index 61cefd0ddc..7bc7fc29d3 100644 --- a/docs/zh-CN/docs/advanced/sql-mode.md +++ b/docs/zh-CN/docs/advanced/sql-mode.md @@ -71,6 +71,12 @@ show session variables 在此模式下,'||'符号是一种字符串连接符号(同CONCAT()函数),而不是'OR'符号的同义词。(e.g., `'a'||'b' = 'ab'`, `1||0 = '10'`) +2. `NO_BACKSLASH_ESCAPES` + + 启用此模式将禁用反斜杠字符(\)作为字符串和标识符中的转义字符。启用此模式后,反斜杠将变成一个普通字符,与其他字符一样。(e.g., `\b = \\b`, ) + + + ## 复合mode (后续补充)