SnowConvert: Teradata Conversion Settings¶
General Conversion Settings¶
General Result Settings¶
Comment objects with missing dependencies: Flag to indicate if the user wants to comment on nodes that have missing dependencies.
Disable EWI comments generation (errors, warnings and issues): Flag to indicate whether EWIs comments (Errors, Warnings, and Issues) will not be generated on the converted code. The default is false
Generate XML-tags for SQL statements in Stored Procedures: Flag to indicate whether the SQL statements SELECT, INSERT, CREATE, DELETE, UPDATE, DROP, MERGE in Stored Procedures will be tagged on the converted code. This feature is used for easy statement identification on the migrated code. Wrapping these statements within these XML-like tags allows for other programs to quickly find and extract them. The decorated code looks like this:
//<SQL_DELETE EXEC(DELETE FROM SB_EDP_SANDBOX_LAB.PUBLIC.USER_LIST,[]) //SQL_DELETE!>
Separate Period Data-type definitions and usages into begin and end Data-Time fields: This flag is used to indicate that the tool should migrate any use of the PERIOD datatype as two separate DATETIME fields that will hold the original period begin and end values, anytime a period field or function is migrated using this flag SSC-EWI-TD0053 will be added to warn about this change.
Input Code:
CREATE TABLE myTable( col1 PERIOD(DATE), col2 VARCHAR(50), col3 PERIOD(TIMESTAMP) );
Output Code:
CREATE OR REPLACE TABLE myTable ( col1 VARCHAR(24) !!!RESOLVE EWI!!! /*** SSC-EWI-TD0053 - SNOWFLAKE DOES NOT SUPPORT THE PERIOD DATATYPE, ALL PERIODS ARE HANDLED AS VARCHAR INSTEAD ***/!!!, col2 VARCHAR(50), col3 VARCHAR(58) !!!RESOLVE EWI!!! /*** SSC-EWI-TD0053 - SNOWFLAKE DOES NOT SUPPORT THE PERIOD DATATYPE, ALL PERIODS ARE HANDLED AS VARCHAR INSTEAD ***/!!! ) COMMENT = '{"origin":"sf_sc","name":"snowconvert","version":{"major":1, "minor":0},{"attributes":{"component":"teradata"}}' ;
Set encoding of the input files: The encoding code page number is used for parsing the source files. We only accept encodings supported by .NET Core (https://docs.microsoft.com/en-us/dotnet/api/system.text.encoding?view=net-5.0#list-of-encodings). Here are the ones supported at the moment:
Code Page | Name | Display Name |
---|---|---|
Code Page | Name | Display Name |
1200 | utf-16 | Unicode |
1201D | unicodeFFFE | Unicode (Big endian) |
12000 | utf-32 | Unicode (UTF-32) |
12001 | utf-32BE | Unicode (UTF-32 Big endian) |
20127 | us-ascii | US-ASCII |
28591 | iso-8859-1 | Western European (ISO) |
65000 | utf-7 | Unicode (UTF-7). Not available in .NET 5 |
65001 | utf-8 | Unicode (UTF-8). Default encoding |
Use COLLATE for Case Specification: This flag indicates whether to use COLLATE or UPPER to preserve Case Specification functionality, e.g. CASESPECIFIC or NOT CASESPECIFIC. By default, it is turned off, meaning that the UPPER function will be used to emulate case insensitivity (NOT CASESPECIFIC). To learn more about how Case Specification is handled by SnowConvert check here.
Note
To review the Settings that apply to all supported languages, go to the following article.
Session Mode Settings¶
This settings sub-page is used to indicate the Session Mode of the input code.
SnowConvert handles Teradata code in both TERA and ANSI modes. Currently, this is limited to the default case specification of character data and how it affects comparisons. By default, the Session Mode is TERA.
You can learn more about how SnowConvert handles and converts code depending on the session mode, check here.
DB Objects Names Settings¶
Schema: The string value specifies the custom schema name to apply. If not specified, the original database name will be used. Example: DB1.myCustomSchema.Table1.
Database: The string value specifies the custom database name to apply. Example: MyCustomDB.PUBLIC.Table1.
Default: None of the above settings will be used in the object names.
Prepare Code Settings¶
Prepare my code: Flag to indicate whether the input code should be processed before parsing and transformation.
Format Conversion Settings¶
Character to Number default scale: An integer value for the CHARACTER to Approximate Number transformation (Default: 10).
Default TIMESTAMP format: String value for the TIMESTAMP format (Default: “YYYY/MM/DD HH:MI:SS”).
Default DATE format: String value for the DATE format (Default: “YYYY/MM/DD”).
Source TIMEZONE: String value for the TIMEZONE format (Default: “GMT-5”).
Default TIME format: String value for the TIME format (Default: “HH:MI:SS”).
Target Language for BTEQ, Procedures/Macros¶
Specifies the target language to convert Bteq and Mload script files. Currently supported values are SnowScript and Python. The default value is set to Python.
String value specifying the target language to convert Stored procedures and Macros. Currently supported are: SnowScript and JavaScript. The default value is set to SnowScript.
Reset Settings: The reset settings option appears on every page. If you’ve made changes, you can reset SnowConvert to its original default settings.