MSCEWI3058

NLS_DATE_FORMAT session parameter does not enforce the input format in Oracle.

This is a deprecated version of the SnowConvert documentation, please visit the official site HERE.

Severity

Low

Description

Oracle may recognize more input formats than the one is set in the NLS_DATE_FORMAT parameter. This parameter also modifies the output format for dates. In the converted code the DATE_INPUT_FORMAT and DATE_OUTPUT_FORMAT Snowflake session parameters are set with the same value in order to emulate the functionality in Oracle.

Example Code

Input Code:

alter session set nls_date_format = 'DD-MM-YYYY';

Output Code:

alter session set /*** MSC-WARNING - MSCEWI3058 - NLS_DATE_FORMAT SESSION PARAMETER DOES NOT ENFORCE THE INPUT FORMAT IN ORACLE ***/
 DATE_INPUT_FORMAT = 'DD-MM-YYYY' DATE_OUTPUT_FORMAT = 'DD-MM-YYYY';

Recommendations

Last updated