Uploaded image for project: 'IMPALA'
  1. IMPALA
  2. IMPALA-9131

Use single quotes when printing out FORMAT clause within CAST.

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: Impala 3.3.0
    • Fix Version/s: None
    • Component/s: Frontend
    • Labels:
      None
    • Epic Color:
      ghx-label-11

      Description

      Here the content of the FORMAT clause is surrounded by double quotes.

      select cast('2016/10/10' as date format 'YYYY/MM/DD');
      +------------------------------------------------+
      | cast('2016/10/10' as date format "yyyy/mm/dd") |
      +------------------------------------------------+
      | 2016-10-10                                     |
      +------------------------------------------------+
      

      In order to follow SQL standards this should be surrounded by single quotes regardless of how the user gave the FORMAT clause.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                gaborkaszab Gabor Kaszab
                Reporter:
                gaborkaszab Gabor Kaszab
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: