[ https://issues.apache.org/jira/browse/SPARK-36635?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17409222#comment-17409222 ]
weixiuli commented on SPARK-36635: ---------------------------------- It didn't work before either. > spark-sql do NOT support that select name expression as string type now > ------------------------------------------------------------------------ > > Key: SPARK-36635 > URL: https://issues.apache.org/jira/browse/SPARK-36635 > Project: Spark > Issue Type: Bug > Components: SQL > Affects Versions: 3.1.0, 3.1.2 > Reporter: weixiuli > Priority: Major > > The follow statement would throw an exception. > {code:java} > sql("SELECT age as 'a', name as 'n' FROM VALUES (2, 'Alice'), (5, 'Bob') > people(age, name)") > {code} > {code:java} > // Exception information > Error in query: > mismatched input ''a'' expecting {<EOF>, ';'}(line 1, pos 14) > == SQL == > SELECT age as 'a', name as 'n' FROM VALUES (2, 'Alice'), (5, 'Bob') > people(age, name) > --------------^^^ > {code} -- This message was sent by Atlassian Jira (v8.3.4#803005) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org For additional commands, e-mail: issues-h...@spark.apache.org