Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-37471

spark-sql support nested bracketed comment

    XMLWordPrintableJSON

Details

    • Task
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 3.2.0
    • 3.2.1, 3.3.0
    • SQL
    • None

    Description

      /*
      select  
      select /* BROADCAST(b) */ 4\\;
      */
      select  1
      ;
      

      failed in spark-sql -f

      /usr/share/spark-3.2/bin/spark-sql --verbose  -f test.sql
      
      Spark master: yarn, Application Id: application_1632999510150_6968442
      /* sielect /* BROADCAST(b) */ 4
      Error in query:
      mismatched input '4' expecting {'(', 'ADD', 'ALTER', 'ANALYZE', 'CACHE', 'CLEAR', 'COMMENT', 'COMMIT', 'CREATE', 'DELETE', 'DESC', 'DESCRIBE', 'DFS', 'DROP', 'EXPLAIN', 'EXPORT', 'FROM', 'GRANT', 'IMPORT', 'INSERT', 'LIST', 'LOAD', 'LOCK', 'MAP', 'MERGE', 'MSCK', 'REDUCE', 'REFRESH', 'REPLACE', 'RESET', 'REVOKE', 'ROLLBACK', 'SELECT', 'SET', 'SHOW', 'START', 'TABLE', 'TRUNCATE', 'UNCACHE', 'UNLOCK', 'UPDATE', 'USE', 'VALUES', 'WITH'}(line 1, pos 30)
      
      == SQL ==
      /* sielect /* BROADCAST(b) */ 4
      ------------------------------^^^
      
      

      Attachments

        Activity

          People

            angerszhuuu angerszhu
            angerszhuuu angerszhu
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: