You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by kx...@apache.org on 2024/03/08 02:28:32 UTC
(doris) branch revert-31891-Pick_31890 created (now 525389edaa8)
This is an automated email from the ASF dual-hosted git repository.
kxiao pushed a change to branch revert-31891-Pick_31890
in repository https://gitbox.apache.org/repos/asf/doris.git
at 525389edaa8 Revert "[Fix](load) Fix insert into wrong value #31890 (#31891)"
This branch includes the following new commits:
new 525389edaa8 Revert "[Fix](load) Fix insert into wrong value #31890 (#31891)"
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
(doris) 01/01: Revert "[Fix](load) Fix insert into wrong value #31890 (#31891)"
Posted by kx...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
kxiao pushed a commit to branch revert-31891-Pick_31890
in repository https://gitbox.apache.org/repos/asf/doris.git
commit 525389edaa848ceb0e951608bd8314e6aa7cd788
Author: Kang <kx...@gmail.com>
AuthorDate: Fri Mar 8 10:28:26 2024 +0800
Revert "[Fix](load) Fix insert into wrong value #31890 (#31891)"
This reverts commit d44adb087a4e5c0394a0b18cab5c0e6cda9359d6.
---
fe/fe-core/src/main/jflex/sql_scanner.flex | 2 +-
regression-test/data/insert_p0/insert.out | 3 ---
regression-test/suites/insert_p0/insert.groovy | 16 ----------------
3 files changed, 1 insertion(+), 20 deletions(-)
diff --git a/fe/fe-core/src/main/jflex/sql_scanner.flex b/fe/fe-core/src/main/jflex/sql_scanner.flex
index 583fc20243c..314a04599b0 100644
--- a/fe/fe-core/src/main/jflex/sql_scanner.flex
+++ b/fe/fe-core/src/main/jflex/sql_scanner.flex
@@ -739,7 +739,7 @@ EndOfLineComment = "--" !({HintContent}|{ContainsLineTerminator}) {LineTerminato
{SingleQuoteStringLiteral} {
return newToken(SqlParserSymbols.STRING_LITERAL,
- escapeBackSlash(yytext().substring(1, yytext().length()-1), sql_mode));
+ escapeBackSlash(yytext().substring(1, yytext().length()-1), sql_mode).replaceAll("''", "'"));
}
{DoubleQuoteStringLiteral} {
diff --git a/regression-test/data/insert_p0/insert.out b/regression-test/data/insert_p0/insert.out
index 38a2a818ab5..b582f45123d 100644
--- a/regression-test/data/insert_p0/insert.out
+++ b/regression-test/data/insert_p0/insert.out
@@ -202,6 +202,3 @@
44980 113.8777 again 1987-04-09 2010-01-02T04:03:06 false -0.01 0E-10
44980 113.8777 again 1987-04-09 2010-01-02T04:03:06 false -0.01 0E-10
--- !select --
-3 replace(cdate,'-','')
-
diff --git a/regression-test/suites/insert_p0/insert.groovy b/regression-test/suites/insert_p0/insert.groovy
index cd3ba176bc8..573d5d8366c 100644
--- a/regression-test/suites/insert_p0/insert.groovy
+++ b/regression-test/suites/insert_p0/insert.groovy
@@ -83,20 +83,4 @@ suite("insert") {
sql "sync"
qt_insert """ select * from mutable_datatype order by c_bigint, c_double, c_string, c_date, c_timestamp, c_boolean, c_short_decimal"""
- def table = "insert_with_quote"
- sql """ DROP TABLE IF EXISTS ${table} """
- sql """
- CREATE TABLE ${table} (
- `id` int(11) NULL,
- `dim1` string NULL
- ) ENGINE=OLAP
- UNIQUE KEY(`id`)
- DISTRIBUTED BY HASH(`id`) BUCKETS 1
- PROPERTIES (
- "replication_allocation" = "tag.location.default: 1"
- );
- """
- sql """insert into ${table}(id,dim1) values(3,\'replace(cdate,\\\'-\\\',\\\'\\\')\')"""
- qt_select """ select * from ${table} """
-
}
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org