N Campbell created SPARK-10502:
----------------------------------

             Summary: tidy up the exception message text to be less 
verbose/"User friendly"
                 Key: SPARK-10502
                 URL: https://issues.apache.org/jira/browse/SPARK-10502
             Project: Spark
          Issue Type: Bug
          Components: SQL
    Affects Versions: 1.3.1
            Reporter: N Campbell
            Priority: Minor


When a statement is parsed, it would be preferred is the exception text were 
more aligned with other vendors re indicating the syntax error without the 
inclusion of the verbose parse tree.


 select tbint.rnum,tbint.cbint, nth_value( tbint.cbint, '4' ) over ( order by 
tbint.rnum) from certstring.tbint 


Errors:
org.apache.spark.sql.AnalysisException: 
Unsupported language features in query: select tbint.rnum,tbint.cbint, 
nth_value( tbint.cbint, '4' ) over ( order by tbint.rnum) from certstring.tbint
TOK_QUERY 1, 0,40, 94
  TOK_FROM 1, 36,40, 94
    TOK_TABREF 1, 38,40, 94
      TOK_TABNAME 1, 38,40, 94
        certstring 1, 38,38, 94
        tbint 1, 40,40, 105
  TOK_INSERT 0, -1,34, 0
    TOK_DESTINATION 0, -1,-1, 0
      TOK_DIR 0, -1,-1, 0
        TOK_TMP_FILE 0, -1,-1, 0
    TOK_SELECT 1, 0,34, 12
      TOK_SELEXPR 1, 2,4, 12
        . 1, 2,4, 12
          TOK_TABLE_OR_COL 1, 2,2, 7
            tbint 1, 2,2, 7
          rnum 1, 4,4, 13
      TOK_SELEXPR 1, 6,8, 23
        . 1, 6,8, 23
          TOK_TABLE_OR_COL 1, 6,6, 18
            tbint 1, 6,6, 18
          cbint 1, 8,8, 24
      TOK_SELEXPR 1, 11,34, 31
        TOK_FUNCTION 1, 11,34, 31
          nth_value 1, 11,11, 31
          . 1, 14,16, 47
            TOK_TABLE_OR_COL 1, 14,14, 42
              tbint 1, 14,14, 42
            cbint 1, 16,16, 48
          '4' 1, 19,19, 55
          TOK_WINDOWSPEC 1, 25,34, 82
            TOK_PARTITIONINGSPEC 1, 27,33, 82
              TOK_ORDERBY 1, 27,33, 82
                TOK_TABSORTCOLNAMEASC 1, 31,33, 82
                  . 1, 31,33, 82
                    TOK_TABLE_OR_COL 1, 31,31, 77
                      tbint 1, 31,31, 77
                    rnum 1, 33,33, 83

scala.NotImplementedError: No parse rules for ASTNode type: 882, text: 
TOK_WINDOWSPEC :
TOK_WINDOWSPEC 1, 25,34, 82
  TOK_PARTITIONINGSPEC 1, 27,33, 82
    TOK_ORDERBY 1, 27,33, 82
      TOK_TABSORTCOLNAMEASC 1, 31,33, 82
        . 1, 31,33, 82
          TOK_TABLE_OR_COL 1, 31,31, 77
            tbint 1, 31,31, 77
          rnum 1, 33,33, 83
" +
         
org.apache.spark.sql.hive.HiveQl$.nodeToExpr(HiveQl.scala:1261)



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org

Reply via email to