Send feedback on this topic.
Teradata.Client.Provider
Generated Data Retrieval (Identity Column Support)
.NET Data Provider for Teradata > Developer's Guide > Working with the Data Provider Features > Generated Data Retrieval (Identity Column Support)

Identity columns may be generated automatically by the database, or they may be supplied by the client application depending upon the table creation options. Table cardinality is limited by the maximum value of the identity column numeric data type. The maximum numeric data type is decimal(18,0). Even though the .NET Data Provider for Teradata and the Advanced SQL Engine support precision of 38 digits, the maximum identity value supported by the SQL Engine is limited by the data type decimal(18,0).

Generated data retrieval contains 3 options for retrieval of results from an insert or insert/select statement types:

  1. A table identity column value may be returned
  2. All column values
  3. The default behavior will return the result of the query and no identity column information.

These options may be selected from a new property created in TdCommand. The new property is GeneratedDataBehavior and the values are:

Provider Supported Features

The SQL statement types supported by this feature are:

  1. Inserts
  2. Insert-Selects
  3. Multi-Statement Inserts

Generated data retrieval may also be utilized against Teradata tables that do not contain an identity column.  Column information is returned while specifying GeneratedDataBehavior of AllColumns.   The values of GeneratedDataBehavior include IdentityColumn, AllColumns and None.   None is the default setting, which disables this information retrieval.

The following are examples of accessing the generated data retrieval feature.

Feature Support Description
TdCommand Support Example A new TdCommand property to support this feature.
TdDataAdapter Support Example The TdDataAdapter may be used to generate commands without a TdCommandBuilder.
TdDataAdapter and TdCommandBuilder Support Example TdCommandBuilder is utilized to build commands for TdDataAdapter.
Non-Identity Column Table Support Example Returning Default Column Values.
Visual Studio Support Visual Studio Designer support (Teradata Generated Data Behavior Support).