SnowConvert AI - General Functional Differences¶
SSC-FDM-0001¶
Views selecting all columns from a single table are not required in Snowflake
Note
Some parts of the output code are omitted for clarity reasons.
Description¶
Views that only select all columns of a single table and do not have any filtering clauses are not required in Snowflake and may affect performance.
Code Example¶
Input Code (Oracle):¶
Generated Code:¶
Best Practices¶
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0002¶
Correlated Subquery May Have Functional Differences
Description¶
This message is reported when a Correlated Subquery (subquery that refers to a column from the outer query) is located. This type of subqueries can, in some cases, present some functional differences in Snowflake (Working with Subqueries).
Code Example¶
Input Code:¶
Generated Code:¶
Best Practices¶
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0003¶
Conversion Rate Inconsistency
Description¶
This message is reported when a conversion rate inconsistency is found on the assessment field specified. These situations are resolved automatically by SnowConvert AI, so this is just an informative warning.
Note
This Informative warning will only be visible in the assessment documents and not the output code
Best Practices¶
Despite SnowConvert AI’s ability to automatically fix the issue, you can still notify the SnowConvert AI support team by emailing snowconvert-support@snowflake.com and specifying the issue.
SSC-FDM-0004¶
External table translated to regular table
Description¶
This warning is added to clauses related to external handling. Snowflake recommends that all data should be managed inside the Snowflake data storage. For more information on this subject, see the Snowflake data storage considerations.
Code Example¶
Input Code:¶
Generated Code:¶
Best Practices¶
The data stored in files of the external tables must be somehow moved into the Snowflake database.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0005¶
TIME ZONE not supported for time data type
Description¶
The Time data type in Snowflake does not store Timezone values
TIME internally stores “wallclock” time, and all operations on TIME values are performed without taking any time zone into consideration. For more information, see the Snowflake TIME data type documentation.
Example Code¶
Input Code:¶
Generated Code:¶
Best Practices¶
No end-user action is required.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0006¶
Number type column may not behave similarly in Snowflake
Description¶
This functional difference message appears when a NUMBER Type column is being created within a Table. The reason for this is due to arithmetic differences when performing operations related to the scales of intermediate values in Snowflake which could make some operations fail. For more information please refer to Snowflake’s post on intermediate numbers in Snowflake and Number out of representable range.
To avoid these arithmetic issues, you can run data samplings to verify the needed precision and scales for these operations.
Example Codes¶
Simple Table with Number Columns¶
Input Code (Oracle):¶
Generated Code:¶
Arithmetic Issue Examples¶
The next examples show how the arithmetic issues can happen when using Number columns:
Snowflake Code with Division Error:¶
Snowflake Code with Multiplication Error:¶
When running either SELECT statements Snowflake will return an error:
Number out of representable range: type FIXEDSB16{nullable}, value 1.0000000000000000000
This is due to the intermediate operation’s result overflowing Snowflake’s maximum capacity; reducing the number scales by 1 on each example will fix the error and work normally:
Snowflake Code with Division:¶
Snowflake Code with Multiplication:¶
For this reason, SnowConvert AI sets the default scale of Numbers to 18, minimizing the number of errors when migrating.
Best Practices¶
Verify that your operations’ intermediate values don’t exceed a scale of 37, as that is Snowflake’s maximum.
Run Data Samplings on your data, to make sure you have the required precision and scales before running any operations.
In most cases, after doing some data sampling or discussing with the business you might come to the conclusion that the precision can be different. For example, for
MONEYcolumns a typical precision isNUMBER(20,4). In snowflake you cannot easily alter a column data type, you can check this post on our forum which provides some guidance on how to alter your columns data types and preserve your data.If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0007¶
Element with missing dependencies
Note
Some parts of the output code are omitted for clarity reasons
Description¶
There is a missing dependency for an object, Snow Convert could not resolve some data types. Also there exists a possibility to have a deployment error if the dependency was not in the source code.
Example Code¶
Input Code:¶
Generated Code:¶
Note
Note that the TABLE1 definition is missing.
Best Practices¶
Make sure all the dependencies of the objects are in the source code.
If not, find the references to the object in the code and check if the operations are well managed.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0008¶
On Commit not supported
Note
Some parts of the output code are omitted for clarity reasons.
Description ¶
The ON COMMIT clauses in your CREATE TABLE statement have been commented out. Snowflake does not support the ON COMMIT clause, as it’s typically used for temporary tables in other SQL dialects. If you need to manage transaction-specific behavior, consider using Snowflake’s transactions or temporary tables with explicit TRUNCATE or DROP statements instead.
Example Code¶
Input Code¶
Generated Code¶
SSC-FDM-0009¶
GLOBAL TEMPORARY TABLE functionality not supported.
Description ¶
Global temporary tables are considered a complex pattern, due to the fact they can come in several variations, as indicated in Snowflake’s documentation.
Example Code¶
Input Code¶
Generated Code¶
Best Practices¶
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0010¶
Type changed to Date.
Description ¶
This message is shown when SnowConvert AI finds a DEFAULT SYSDATE and the data type is NOT a DATE or TIMESTAMP datatype. In this case, the data type is changed to DATE.
Example Code¶
Input Code¶
Generated Code¶
Best Practices¶
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0011¶
Column Name Is Snowflake Reserved Keyword.
Note
This FDM is deprecated, please refer to SSC-EWI-0045 documentation.
Description ¶
Column names that are valid for the source language but are reserved keywords in Snowflake.
Example Code¶
Input Code (Oracle):¶
Generated Code:¶
Best Practices¶
Consider renaming the columns that use names that are not supported in Snowflake.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0012¶
Constraint Name in some constraints is not Supported.
Description ¶
This message is added when a constraint is of type Null, Not Null, or default and was defined with a name. Snowflake does not support the name in those constraints. For that, SnowConvert AI will remove it and add the comment.
Example Code¶
Input Code¶
Generated Code¶
Best Practices¶
No end-user action is required.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0013¶
Timezone expression could not be mapped
Description ¶
This FDM message is added to indicate scenarios where the actual value of a timezone expression cannot be determined, and therefore, the translated results might be different. When the timezone value used is a literal string, SnowConvert AI can take it and map it to its corresponding timezone value in Snowflake. However, when this value is specified by an expression, SnowConvert AI cannot get the timezone value that will be used at runtime and, therefore, cannot map this value to its corresponding Snowflake equivalent.
Example Code¶
Input Code (Oracle)¶
Generated Code¶
Input Code (Teradata)¶
Generated Code¶
¶
Note
Timezone Compatibility in Oracle
The majority of timezone name expressions in Oracle are directly supported in Snowflake, when this is the case, the migration will run without issues. Additionally, here is a list of which ones are not supported by Snowflake at the moment, and therefore will include the functional difference message.
Africa/Doula
Asia/Ulaanbaator
Asia/Yetaterinburg
Canada/East-Saskatchewan
CST
PST
US/Pacific-New
Best Practices¶
No end-user action is required.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0014¶
Check statement not supported.
Note
This FDM is deprecated, please refer to SSC-EWI-0035 documentation.
Description¶
CHECK constraint is not supported by Snowflake but it does not affect functionally.
Example Code¶
Input Code Oracle :¶
Generated Code: ¶
Input Code Teradata: ¶
Generated Code: ¶
Input Code SqlServer¶
Generated Code:¶
Best Practices¶
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0015¶
Referenced custom type in query not found.
Description ¶
This error happens when the definition for a Custom Type was not found or an Oracle built-in data type was not recognized by SnowConvert.
Example code¶
Input Code (Oracle):¶
Generated Code:¶
Best Practices¶
Verify that the type that the referenced data type was defined in the input code.
Check the Snowflake data types documentation to find an equivalent for the data type.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0016¶
Constants are not supported by Snowflake Scripting. It was transformed to a variable.
Description ¶
Snowflake Scripting does not support constants. Therefore, all constants inside procedures are being transformed into variables when the Snowflake Scripting flag is active.
Example code¶
Oracle:¶
Snowflake Scripting:¶
Best Practices¶
No end-user actions are required.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0017¶
WITH SYSTEM VERSIONING clause is not supported by Snowflake
Description¶
The WITH SYSTEM VERSIONING clause in ANSI SQL is used to enable system versioning for a table, allowing you to maintain a history of changes to the table’s data over time. This clause is not supported by Snowflake.
Code Example¶
Input Code:¶
Generated Code:¶
Best Practices¶
You can use Time Travel in Snowflake, Time Travel enables accessing historical data (that is, data that has been changed or deleted) at any point within a defined period. It serves as a powerful tool for performing the following tasks:
Restoring data-related objects (tables, schemas, and databases) that might have been accidentally or intentionally deleted.
Duplicating and backing up data from key points in the past.
Analyzing data usage/manipulation over specified periods of time.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0018¶
CHARACTER SET clause is not supported by Snowflake.
Description¶
The column option CHARACTER SET determines the allowed set of characters that can be stored in the column, this clause is not supported by Snowflake.
Code Example¶
Input Code:¶
Generated Code:¶
Best Practices¶
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0019¶
Semantic information could not be loaded.
Description¶
This warning lets the user know that SnowConvert AI was not able to load semantic information for a specific object. This is most likely caused because if there is a duplicated object with the same name, SnowConvert AI could not load the semantic information of this object and complete the analysis.
Example Code¶
Input Code:¶
Generated Code: ¶
Best Practices¶
Check for duplicate objects in the input code since this may affect the loading of semantic information.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0020¶
Multiple result sets are returned in temporary tables
Description¶
Snowflake Scripting procedures only allow one result set to be returned per procedure.
To replicate Teradata behavior, when there are two or more result sets to return, they are stored in temporary tables. The Snowflake Scripting procedure will return an array containing the name of the temporary tables.
Example code¶
Input Code (Teradata):¶
Generated Code:¶
Best Practices¶
To obtain the result sets, it is necessary to run a SELECT query with the name of the temporary tables returned by the procedure.
As much as possible, avoid procedures that return multiple result sets; instead, make them single-responsibility for more direct results.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0021¶
Create Index Not Supported
Description¶
Due to architectural reasons, Snowflake does not support indexes so, SnowConvert AI will comment out all the code related to the creation of indexes. Snowflake automatically creates micro-partitions for every table that help speed up the performance of DML operations, the user does not have to worry about creating or managing these micro-partitions.
Usually, this is enough to have a very good query performance however, there are ways to improve it by creating data clustering keys. Snowflake’s official page provides more information about micro-partitions and data clustering.
Example Code¶
Input Code (Oracle):¶
Generated Code:¶
Best Practices¶
Data clustering might be a way to speed up query performance on tables.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0022¶
Window frame unit was changed to Rows
Severity¶
Low
Description¶
This warning is added when an unsupported Window Frame Unit was changed into Rows, leading to output differences. One example of this is the GROUPS unit, which is not supported by Snowflake.
Please note that this message is also used in cases where a Window Frame Unit is partially unsupported leading to it being changed, like the RANGE unit.
Example Code¶
Given the following data as an example to explain it.
C_NAME |
C_BIRTH_DAY |
|---|---|
USA |
1 |
USA |
4 |
Poland |
9 |
Canada |
10 |
USA |
5 |
Canada |
12 |
Costa Rica |
3 |
Poland |
4 |
USA |
2 |
Costa Rica |
7 |
Costa Rica |
10 |
Oracle:¶
Code¶
SELECT
C_NAME,
SUM(C_BIRTH_DAY)
OVER (ORDER BY C_BIRTH_DAY
RANGE BETWEEN UNBOUNDED PRECEDING AND 1 PRECEDING) AS MAX1
FROM WINDOW_TABLE;
Result¶
C_NAME |
MAX1 |
|---|---|
USA |
- |
USA |
1 |
Costa Rica |
3 |
USA |
6 |
Poland |
6 |
USA |
14 |
Costa Rica |
19 |
Poland |
26 |
Canada |
35 |
Costa Rica |
35 |
Canada |
55 |
Snowflake:¶
Code¶
Result¶
C_NAME |
MAX1 |
|---|---|
USA |
- |
USA |
1 |
Costa Rica |
3 |
USA |
6 |
Poland |
10 |
USA |
14 |
Costa Rica |
19 |
Poland |
26 |
Canada |
35 |
Costa Rica |
45 |
Canada |
55 |
Best Practices¶
Ensure deterministic ordering for rows to ensure deterministic outputs when running in Snowflake.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0023¶
A Global Temporary Table is being referenced.
Severity¶
Medium
Description¶
SnowConvert AI transforms Global Temporary tables into regular Create Table. References to these tables may behave different than expected.
Code example¶
Input¶
Output¶
Best Practices¶
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0024¶
Functionality is not currently supported by Snowflake Scripting
Note
This FDM is deprecated, please refer to SSC-EWI-0058 documentation.
Description¶
This error happens when a statement used in a create procedure is not currently supported by Snowflake Scripting.
Example code¶
Input Code (Oracle):¶
Generated Code:¶
Best Practices¶
No end-user actions are required.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0026¶
Type not supported by Snowflake
Note
This FDM is deprecated, please refer to SSC-EWI-0028 documentation.
Description¶
This message appears when a type is not supported in Snowflake.
Example¶
Input Code (Oracle):¶
Generated Code:¶
Best Practices¶
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0027¶
Removed next statement, not applicable in Snowflake.
Note
Some parts in the output code are omitted for clarity reasons.
Description¶
This message appears when a specific statement is not applicable in Snowflake, it means that there is no Snowflake equivalent for this statement and it is no longer needed, and for that reason, it is removed from the source code. However, SnowConvert AI keeps the original statement as part of the comment at the end.
Example Code¶
Input Code: ¶
Generated Code: ¶
Best Practices¶
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0028¶
Not supported.
Note
This FDM is deprecated, please refer to SSC-EWI-0021 documentation.
Description¶
This message appears when a specific node or statement from the source code is not supported in Snowflake.
Example Code¶
Input Code: ¶
Generated Code:¶
Best Practices¶
If this error happens, it is because there is no Snowflake equivalent for the node that is being converted.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0029¶
User defined function was transformed to a Snowflake procedure.
Warning
This EWI is deprecated, please refer to SSC-EWI-0068 documentation
Severity¶
Low
Description¶
Snowflake user defined functions do not support the same features as Oracle or SQL Server. To maintain the functional equivalence the function is transformed to a Snowflake stored procedure. This will affect their usage in queries.
Example Code¶
SQL Server:¶
Input Code¶
Generated Code¶
Oracle:¶
Input Code¶
Generated Code¶
Best Practices¶
Separate the inside queries to maintain the same logic.
The source code may need to be restructured to fit with the Snowflake user-defined functions approach.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0030¶
Replaced invalid characters for new identifier
Description¶
The given identifier has invalid characters for the output language. Those characters were replaced with their UTF-8 codes.
Example Code¶
Input Code (Oracle):¶
Generated Code:¶
Best Practices¶
No end-user actions are required.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0031¶
Dynamic Table required parameters set by default
Description¶
Materialized Views (and Join Indexes in the case of Teradata) are migrated to Dynamic Tables in Snowflake. Dynamic Tables require two parameters to be set: TARGET_LAG and WAREHOUSE.
If these parameters are not set in the configuration options, they are set by default during conversion.
Read more about the required Dynamic Tables parameters here.
Example Code¶
Input Code (Oracle):¶
Generated Code:¶
Best Practices¶
Configure the dynamic table required parameters according to your needs.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0032¶
Parameter is not a literal value, transformation could not be fully applied
Description¶
For multiple transformations, SnowConvert AI sometimes requires to validate the contents of a parameter, which is only possible if the parameter is a literal value.
This message is generated to warn the user that SnowConvert AI could not retrieve the value of the parameter because it was passed by reference, causing the transformation of the function or statement to not be completed.
Example Code¶
Input Code (Redshift):¶
Generated Code:¶
Best Practices¶
Try to provide the specified parameter as a literal value.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0033¶
Sample clause behaves differently in Snowflake.
Description¶
This message is generated to showcase the functional difference while sampling rows in Snowflake. The differences are related to the quantity of rows retrieved. When in Teradata there is the same quantity of rows in the non-deterministic output, it may change in Snowflake and return a few rows more or less. This is because a probability related topic and it is expected to behaves like that in Snowflake.
If there is a requirement of retrieving the same values and the same quantity, a deterministic output, it is recommended to use a seed in the Snowflake query.
Example Code¶
Input Code (Teradata):¶
Generated Code:¶
Best Practices¶
Try to use the seed part of the query when it is required a deterministic output.
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0034¶
Struct converted to VARIANT. Some of its usages might have functional differences.
Description¶
Snowflake does not natively support the STRUCT data type. SnowConvert AI automatically converts STRUCT to VARIANT. When used in INSERT statements, STRUCT data will be handled using OBJECT_CONSTRUCT. Be aware that this conversion may introduce functional differences in some use cases.
Code Example¶
Input Code:¶
BigQuery¶
Generated Code:¶
Snowflake¶
Best Practices¶
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0035¶
The INFER_SCHEMA function requires a file path without wildcards to generate the table template, replace the FILE_PATH placeholder with it
Description¶
The INFER_SCHEMA function is used in Snowflake to generate the columns definition of a table based on the structure of a file, it requires a LOCATION parameter that specifies the path to a file or folder that will be used to construct the table columns, however, this path does not support regex, meaning that the wildcard * character is not supported.
When the table has no columns, SnowConvert AI will check all URIS to find one that does not use wildcards and use it in the INFER_SCHEMA function, when no URI meets such criteria this FDM and a FILE_PATH placeholder will be generated, the placeholder has to be replaced with the path of one of the files referenced by the external table to generate the table columns.
Code Example¶
Input Code:¶
BigQuery¶
Generated Code:¶
Snowflake¶
Best Practices¶
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0036¶
The transformed numeric/date format may have a different behavior in Snowflake.
Description¶
The transformed numeric formats to Snowflake use Fixed position formats. The transformed format can fail and generate a different output when there are more digits in the integer part of the number than there are digit positions in the format; all digits are printed as # to indicate overflow.
Note
For SQL Server migrations: If you are converting SQL Server code that uses custom single-character date format specifiers (for example, %y, %M, %d, %H, %h, %m, %s) or advanced numeric format specifiers (for example, P, N, %), consider enabling the --enableFormatSpecifiersPreview preview flag. This flag enables access to new Snowflake format specifiers that provide more accurate translations of these formats. See Preview Features Settings for more details.
Note: This requires requesting preview access in your Snowflake account through this form.
Code Example¶
Input Code:¶
Sql Server¶
Generated Code:¶
Snowflake¶
Result¶
Best Practices¶
If the numeric digit does not fit in the format, please update the format by adding more digits based on the possible input data values.
SSC-FDM-0037¶
Statistics function not needed in Snowflake.
Description¶
DROP, COLLECT, or HELP statistics are not needed in Snowflake. Snowflake already collects statistics used for automatic query optimization.
Example Code¶
Input Code:¶
Generated Code¶
Best Practices¶
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0038¶
Micro-partitioning is automatically performed on all Snowflake tables.
Description¶
This message is added to the CREATE TABLE statement when a PARTITION BY clause is present. The PARTITION BY clause, which controls table partitioning in some databases, is not supported in Snowflake.
In Snowflake, all tables are automatically divided into micro-partitions—contiguous units of storage ranging from 50 MB to 500 MB of uncompressed data. This architecture enables highly granular pruning of large tables, which may consist of millions of micro-partitions.
Snowflake automatically stores metadata for each micro-partition, including:
The range of values for each column in the micro-partition.
The number of distinct values.
Additional properties used for optimization and efficient query processing.
Tables are transparently partitioned based on the order of data as it is inserted or loaded. For more details, see the Benefits of Micro-partitioning.
Example Code¶
Input Code:¶
Generated Code¶
Best Practices¶
If you need more support, you can email us at snowconvert-support@snowflake.com
SSC-FDM-0041¶
Default parameters were reordered to the end of the parameter list.
Description¶
Snowflake requires all parameters with default values to appear after all non-default parameters. When SnowConvert AI detects a procedure whose default parameters are not at the end of the parameter list, it automatically reorders them. Code not provided to SnowConvert AI that uses positional arguments may need to be updated to match the new parameter order.
Note
This FDM replaces the deprecated SSC-EWI-0002, which previously only warned about the issue without performing the reorder.
Example Code¶
Input Code (SQL Server):¶
Generated Code (SQL Server):¶
Input Code (Oracle):¶
Generated Code (Oracle):¶
Positional Call Site Conversion¶
When callers use positional arguments and the parameters have been reordered, SnowConvert AI automatically converts them to named arguments:
Best Practices¶
Review all callers of the affected procedure. If positional arguments are used, update them to match the new parameter order or convert them to named arguments.
Consider using named arguments (e.g.,
param1 => value) instead of positional arguments to avoid issues with parameter ordering.If you need more support, you can email us at snowconvert-support@snowflake.com