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

DateTimeOperations should accept SQL like string type

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 2.3.0
    • 2.3.0
    • SQL
    • None

    Description

      spark-sql> SELECT '2017-12-24' + interval 2 months 2 seconds;
      Error in query: cannot resolve '(CAST('2017-12-24' AS DOUBLE) + interval 2 months 2 seconds)' due to data type mismatch: differing types in '(CAST('2017-12-24' AS DOUBLE) + interval 2 months 2 seconds)' (double and calendarinterval).; line 1 pos 7;
      'Project [unresolvedalias((cast(2017-12-24 as double) + interval 2 months 2 seconds), None)]
      +- OneRowRelation
      spark-sql> 
      
      

      Attachments

        Activity

          People

            yumwang Yuming Wang
            yumwang Yuming Wang
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: