Send feedback on this topic.
Teradata.Client.Provider
Restrictions
.NET Data Provider for Teradata > Developer's Guide > Working with the Data Provider Features > TdCommandBuilder and TdDataAdapter Overview > Restrictions

The TdCommandBuilder uses information contained in the SELECT statement that was used to fill the DataTable to build the SQL statements that will be used to push changes made to the DataTable to the underlying SQL table. It will use the table name contained in the FROM clause and the column names that appear in the select list to construct the SQL statements.

Therefore, the FROM clause of the SELECT statement can only contain a reference to a single table. The SELECT statement must also only refer to columns contained in the table specified in the from clause. Columns that perform calculations are not permitted.

The following are additional rules when using the TdDataAdapter with the TdCommandBuilder:

  1. Sub-query can appear in the where clause of the SELECT statement. For example, the following correlated sub-query is allowed:

         SELECT cust-id, cust-name, cust-address
         FROM customer
         WHERE cust-id in (SELECT cust-id FROM invoices WHERE inv-date > '2008-01-01')

  2. The following keywords are not allowed to be used in the SELECT statement. This also applies to the sub-queries that can be used in a where clause.

         Inner, Left, Right, Full, Cross, Outer, Join, GROUP BY,
         HAVING, QUALIFY, SAMPLE, WITH, UNION, EXCEPT, MINUS, INTERSECT

  3. Derived table are not allowed. For example:

         select * from ( select * from customers );

  4. Joins (both inner and outer) of two or more tables are not allowed. For example:

         select * from customers c join orders o on c.custid = o.custid;
         select c.custname, o.itemname from customers c, orders o;

  5. Columns that contain functions, literals, or are calculated are not supported. For example:

         select 'customer id' from customers;
         select substring(custname from 3) from customers;

  6. TdCommandBuilder only supports characters that may be represented in the current session character set. It is recommended to use a Unicode session character set while using TdCommandBuilder. For more information see Using TdCommandBuilder with Extended Object Names.

  7. The TdDataAdapter does not support returning identity columns for insert statements to the DataTable while batch operations are enabled. For more information see UpdateBatchSize and Identity Column Support.