Setting Data Type Conversion Defaults
You can set the default data type conversion settings for your system in Spectrum Management Console. You can override the default formats for individual dataflows in Spectrum Enterprise Designer.
To set the default data type conversion options for your system, follow this procedure.
- Open Spectrum Management Console.
- Go to .
- Click Data Type Conversions.
-
Specify the formats that you want to use for date and time data that is
converted to a string. When the data or time is converted to a string, the
string will be in the format you specify here.
Note: If you leave this field blank, numbers will be formatted in the same way they were in Spectrum Technology Platform 8.0 and earlier. Specifically, no thousands separator is used, the dot (".") is used as the decimal separator, numbers less than 10-3 or greater than or equal to 107 are shown in scientific notation, and negative numbers have a minus sign ("-") in front of them. Also note that if you leave this field blank, numbers that use the bigdecimal data type will always be in the format #,###.000.
You can also specify your own date, time, and number formats if the ones available for selection do not meet your needs. To specify your own date or time format, type the format into the field using the notation described in Date and time patterns. To specify your own number format, type the format into the file using the notation described in Number Patterns.
-
Under Null handling, choose whether to perform type
conversion if a field contains a null value. If you select any of the following
options, either the dataflow or the record containing the null value will fail
based on your selection in the Failure handling
field.
- Fail null string
- Fail the flow or record if type conversion is needed on a string field that contains a null value.
- Fail null Boolean
- Fail the flow or record if type conversion is needed on a Boolean field that contains a null value.
- Fail null numeric
- Fail the flow or record if type conversion is needed on a numeric field that contains a null value. Numeric fields include double, float, long, integer, and Big Decimal fields.
- Fail null date
- Fail the flow or record if type conversion is needed on a date field that contains a null value. This includes date, time, and DateTime fields.
-
In the Failure handling field, specify what to do when a field's
value cannot be automatically converted to the data type required by a
stage.
- Fail the flow
- If a field cannot be converted the flow will fail.
- Fail the record
- If a field cannot be converted the record will fail but the flow will continue to run.
- Initialize the field using default values
- If a field cannot be converted the field's value is replaced with the value you specify here. This option is useful if you know that some records contain bad data and you want to replace the bad data with a default value. Specify a value for each data type.