IBM PureData® System for Analytics (Netezza) non-internal data types that are unsupported in Db2 products

As documented in this topic, some non-internal Netezza® data types do not have corresponding Db2® data types. For information about Db2 support for internal Netezza data types, such as ROWID, see IBM PureData System for Analytics (Netezza) and Db2 differences in internal data types.

The following table lists the non-internal Netezza data types that do not have corresponding Db2 data types.

Table 1. Unsupported Netezza data types
Netezza data type Db2 data type alternatives
BOOL Use one of the following approaches:
  • Use the built-in BOOLEAN type. IBM® Database Harmony Profiler automatically converts BOOL to BOOLEAN.
  • Create a type by using the CREATE TYPE (distinct) statement, as follows:
    CREATE TYPE BOOL AS BOOLEAN WITH WEAK TYPE RULES
BYTEINT (alias INT1) Use one of the following approaches:
  • Use the built-in SMALLINT (SHORT) type. IBM Database Harmony Profiler automatically converts BYTEINT to SMALLINT.
  • Create a type by using the CREATE TYPE (distinct) statement, as follows:
    CREATE TYPE BYTEINT AS SMALLINT WITH WEAK TYPE RULES
Test your queries to ensure that the data type change does not affect results.
INTERVAL (alias TIMESPAN) Consider using the DECIMAL data type to store appropriate date, time, and time stamp duration values. Alternatively, replace the INTERVAL data type with the INTEGER or BIGINT data type, and store the value in units of seconds. Additional work is required to convert the INTEGER value to days, minutes, seconds, etc.
TIME WITH TIMEZONE (alias TIMETZ) Store time zone information in a new separate column of the table. You can use an additional column to store the time zone component and include the value of this column in all time calculations. Alternatively, you can keep the database server on Coordinated Universal Time (UTC) and convert all time-zoned values to UTC.