Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-24157

Strict mode to fail on CAST timestamp <-> numeric

Log workAgile BoardRank to TopRank to BottomBulk Copy AttachmentsBulk Move AttachmentsVotersWatch issueWatchersCreate sub-taskConvert to sub-taskMoveLinkCloneLabelsUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    Description

      There is some interest in enforcing that CAST numeric <-> timestamp is disallowed to avoid confusion among users, e.g., SQL standard does not allow numeric <-> timestamp casting, timestamp type is timezone agnostic, etc.

      We should introduce a strict config for timestamp (similar to others before): If the config is true, we shall fail while compiling the query with a meaningful message.

      To provide similar behavior, Hive has multiple functions that provide clearer semantics for numeric to timestamp conversion (and vice versa):
      https://cwiki.apache.org/confluence/display/Hive/LanguageManual+UDF#LanguageManualUDF-DateFunctions

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            kgyrtkirk Zoltan Haindrich Assign to me
            jcamachorodriguez Jesus Camacho Rodriguez
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - Not Specified
              Not Specified
              Remaining:
              Remaining Estimate - 0h
              0h
              Logged:
              Time Spent - 1h 10m
              1h 10m

              Slack

                Issue deployment