Github user xuanyuanking commented on a diff in the pull request:
https://github.com/apache/spark/pull/22590#discussion_r223414086
--- Diff:
sql/core/src/test/scala/org/apache/spark/sql/execution/datasources/csv/CSVSuite.scala
---
@@ -194,6 +195,22 @@ class CSVSuite extends QueryTest with SharedSQLContext
with SQLTestUtils with Te
checkAnswer(rows, expectedRows)
}
+ test("keep escaped quotes") {
+ val notKeepQuotes = spark.read
+ .format("csv")
+ .option("keepQuotes", false)
+ .load(testFile(keepQuotesFile))
+ var expectedRows = Seq(Row("\"a\"b", "ccc", null, "ddd"), Row("ab",
"cc", null, "c,ddd"))
--- End diff --
Nice case for `"a"b`
nit: so should we add a comments in
https://github.com/apache/spark/pull/22590/files#diff-eb708fbebdf6d20d1ab1b109f5f2cd56R180
to emphasize the behavior mainly effect on keep quotes on the begin and end?
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]