XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Reopened
    • Major
    • Resolution: Unresolved
    • 3.1.0
    • None
    • SQL
    • None

    Description

      While DB2, ORACLE etc support a join expressed as follows, SPARK SQL does not.
      Not supported

      select * from 
        cert.tsint tsint inner join cert.tint tint inner join cert.tbint tbint
           on tbint.rnum = tint.rnum
           on tint.rnum = tsint.rnum
      

      versus written as shown

      select * from 
        cert.tsint tsint inner join cert.tint tint on tsint.rnum = tint.rnum inner join cert.tbint tbint on tint.rnum = tbint.rnum
      
      Unable to find source-code formatter for language: text. Available languages are: actionscript, ada, applescript, bash, c, c#, c++, cpp, css, erlang, go, groovy, haskell, html, java, javascript, js, json, lua, none, nyan, objc, perl, php, python, r, rainbow, ruby, scala, sh, sql, swift, visualbasic, xml, yaml
      ERROR_STATE, SQL state: org.apache.spark.sql.catalyst.parser.ParseException: 
      extraneous input 'on' expecting {<EOF>, ',', '.', '[', 'WHERE', 'GROUP', 'ORDER', 'HAVING', 'LIMIT', 'OR', 'AND', 'IN', NOT, 'BETWEEN', 'LIKE', RLIKE, 'IS', 'JOIN', 'CROSS', 'INNER', 'LEFT', 'RIGHT', 'FULL', 'NATURAL', 'LATERAL', 'WINDOW', 'UNION', 'EXCEPT', 'MINUS', 'INTERSECT', EQ, '<=>', '<>', '!=', '<', LTE, '>', GTE, '+', '-', '*', '/', '%', 'DIV', '&', '|', '^', 'SORT', 'CLUSTER', 'DISTRIBUTE', 'ANTI'}(line 4, pos 5)
      
      == SQL ==
      select * from 
        cert.tsint tsint inner join cert.tint tint inner join cert.tbint tbint
           on tbint.rnum = tint.rnum
           on tint.rnum = tsint.rnum
      -----^^^
      , Query: select * from 
        cert.tsint tsint inner join cert.tint tint inner join cert.tbint tbint
           on tbint.rnum = tint.rnum
           on tint.rnum = tsint.rnum.
      SQLState:  HY000
      ErrorCode: 500051
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            the6campbells N Campbell
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: