srielau commented on code in PR #45470:
URL: https://github.com/apache/spark/pull/45470#discussion_r1523561534


##########
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/parser/ErrorParserSuite.scala:
##########
@@ -39,6 +39,23 @@ class ErrorParserSuite extends AnalysisTest {
       context = ExpectedContext(fragment = "order by q\ncluster by q", start = 
16, stop = 38))
   }
 
+  test("Illegal characters in unquoted identifier") {
+    // scalastyle:off
+    checkError(

Review Comment:
   I have no idea!
   When I run from teh command line I get the full info:
   `spark-sql (default)> use 表1;
   
   [INVALID_IDENTIFIER] The unquoted identifier 表1 is invalid and must be back 
quoted as: `表1`.
   Unquoted identifiers can only contain ASCII letters ('a' - 'z', 'A' - 'Z'), 
digits ('0' - '9'), and underbar ('_').
   Unquoted identifiers must also not start with a digit.
   Different data sources and meta stores may impose additional restrictions on 
valid identifiers. SQLSTATE: 42602 (line 1, pos 4)
   
   == SQL ==
   use 表1
   ----^^^
   
   `
   But when I add a context to checkError it complains:
   `[info] - Illegal characters in unquoted identifier *** FAILED *** (12 
milliseconds)
   [info]   0 did not equal 1 Invalid length of the query context 
(SparkFunSuite.scala:365)
   [info]   org.scalatest.exceptions.TestFailedException:
   `
   
   An investigation for another PR.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to