Last updated
Last updated
Some parts of the output code are omitted for clarity reasons.
Extracts 'Data Part' from the result of the subtraction MINUEND
- SUBTRAHEND
Teradata and Snowflake differ in the parameters that each function respectively might receive and the return type.
Parameters: The main difference between Teradata and Snowflake extract function is that Snowflake does not handle intervals, it only supports dates and times. For further information on this, read and .
Return type: Teradata EXTRACT function returns an integer or decimal(8, 2) value representing the part requested and Snowflake returns a number value representing a date-time of the part requested.
Teradata and Snowflake differ in the parameters that each function respectively might receive and the return type.
MINUEND
TIMESTAMP
Date subtracted from.
SUBTRAHEND
TIMESTAMP
Date subtracted.
INPUT_PART
VARCHAR
Formatted varchar, is the original requested part (same as TIMESTAMP_DIFERENCE
INPUT_PART
) and must be one of these:
'DAY TO HOUR'
'DAT TO MINUTE'
'DAY TO SECOND'
'DAY TO MINUTE'
'HOUR TO MINUTE'
'HOUR TO SECOND'
'MINUTE TO SECOND'
EXTRACT_PART
VARCHAR
Value to be extracted, the request part should be contained in the input part interval, must be 'DAY'
, 'HOUR'
, 'MINUTE'
or 'SECOND'
.
The number of requests part of the extract.
Input:
Output: