Identity columns

There may only be one Identity column per table. If the table being imported actually has multiple identity columns, Import Tables will only count the first identity column imported as an Identity column

Identity columns cannot be set to a specific value on insert or update. If an identity column is one of the primary key columns, it must be specified in the FIELDS(…) parameter of the INSERT command. However, the value in the column will not be inserted into the table, and the value of the column after the INSERT will not reflect the value that was actually inserted.

They are automatically generated on insert. Note: there is no way to retrieve the value without re-reading the row that was just inserted. To re-read the row, you will need to ensure the table has a primary key or unique index that does not contain the identity column.

Note: When compiling IBM i Other Tables on platforms other than IBM i, if you choose to drop the table and reimport the data, identity column values will be regenerated.

Also See

Other Table Concepts

Create RRNO Column