Details
-
Task
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
1.2.1
-
None
-
None
Description
cannot insert symbols in column using the mcsimport with escape_character option
how to repeat
import column value b"bbb or b\bb\ using escape_character '"' or \''
the value including " or \ character is not inserted although using mcsimport with escape_character option
A. file content :
"aaa","b""bbb","c\cc"
|
./mcsimport a c c.csv -E '"' -C '"'
|
Execution time: 0.0988391s
|
Rows inserted: 1
|
Truncation count: 3
|
Saturated count: 0
|
Invalid count: 0
|
|
MariaDB [(none)]> select * from a.c ;
|
+------+------+------+
|
| c | d | e |
|
+------+------+------+
|
| a | b | c |
|
+------+------+------+
|
1 row in set (0.056 sec)
|
|
B.file content:
"aaa","b\"bb","ccc"
|
"aaa","b\\bb\\","c\cc"
|
./mcsimport a c c.csv -E '"' -C '\'
|
Execution time: 0.0930145s
|
Rows inserted: 2
|
Truncation count: 6
|
Saturated count: 0
|
Invalid count: 0
|
|
MariaDB [(none)]> select * from a.c ;
|
+------+------+------+
|
| c | d | e |
|
+------+------+------+
|
| a | b | c |
|
| a | b | c |
|
+------+------+------+
|
2 rows in set (0.040 sec)
|
|