VARIABLE DECLARATION
Description
Declare all variables in a block, except for loop variables, in the block's DECLARE section.
Variable declarations are fully supported by Snowflake.
Grammar Syntax
In Redshift, the CONSTANT
keyword prevents variable reassignment during execution. Since Snowflake does not support this keyword, it is removed during transformation. This does not impact functionality, as the logic should not attempt to reassign a constant variable.
The NOT NULL
constraint in Redshift ensures a variable cannot be assigned a null value and requires a non-null default value. As Snowflake does not support this constraint, it is removed during transformation. However, the default value is retained to maintain functionality.
A variable declare with a Refcursor is transformed to Resultset type, for more information.
Sample Source Patterns
Input Code:
Output Code:
Known Issues
No issues were found.
Related EWIs
SSC-FDM-PG0012: NOT NULL constraint has been removed. Assigning NULL to this variable will no longer cause a failure.
Last updated