DATEDIFF UDF INTERVAL
Description
This UDF is used to resolve operations with intervals like:
INTERVAL - UNKNOWN
UNKNOWN - INTERVAL
DATE - INTERVAL
TIMESTAMP - INTERVAL
Custom UDF overloads
DATEADD_DDIF(string, date)
Parameters
INTERVAL_VALUE: The interval
Stringof the operation.D: The
DATEwhere the interval will be subtracted.
DATEADD_DIFF(date, string)
Parameters
D: The
DATEwhere the interval will be subtracted.INTERVAL_VALUE: The interval
Stringof the operation.
DATEADD_DIFF(string, timestamp)
Parameters
INTERVAL_VALUE: The interval
Stringof the operation.D: The
TIMESTAMPwhere the interval will be subtracted.
DATEADD_DIFF(timestamp, string)
Parameters
D: The
TIMESTAMPwhere the interval will be subtracted.INTERVAL_VALUE: The interval
Stringof the operation.
Usage example
Oracle
Snowflake
Known Issues
1. INTERVAL - INTERVAL Operation is not supported
Snowflake does not support INTERVAL - INTERVAL operations.
Related EWIs
SSC-EWI-OR0036: Types resolution issues, the arithmetic operation may not behave correctly between string and date.
SSC-EWI-OR0095: Operation Between Interval Type and Date Type not Supported.
SSC-FDM-0007: Element with missing dependencies.
SSC-FDM-OR0042: Date Type Transformed To Timestamp Has A Different Behavior.
Last updated
