Try Cast (Teradata Database) - Teradata Warehouse Miner

Teradata Warehouse Miner User Guide - Volume 2ADS Generation

Product
Teradata Warehouse Miner
Release Number
5.4.5
Published
February 2018
Language
English (United States)
Last Update
2018-05-03
dita:mapPath
qhj1503087326201.ditamap
dita:ditavalPath
ft:empty
dita:id
B035-2301
Product Category
Software

This function is only available when connected to a Teradata database.

The Try Cast function attempts to cast the argument from its base data type to another (selected from the Properties dialog). If the casting attempt fails, the Try Cast function returns a result of NULL. When dragging a Try Cast function into a variable, the following tree element is created.

Variable Creation > Input > Variables: SQL Elements pane - Other > Try Cast

The Try Cast Properties dialog automatically appears.

Variable Creation > Input > Variables: SQL Elements pane - Other > Try Cast Properties

Select a data type to attempt to cast to from the Data Type drop-down menu and enter any pertinent data type and/or attribute information in the appropriate field. The Resulting SQL field will display the generated SQL to be executed when run.