The database server loads serial columns with either the values from the original data file or values that the database server automatically generates.
If you want the serial column values to be the values found in the data file, the INSERT statement does not require special handling. On the other hand, if you want the database server to generate the value automatically, omit the serial column from the INSERT statement. For example, if the first column in the table (col1) is the serial column and you use the following statement, the default mechanism provides the serial value:
INSERT INTO mytable (col2, ...) SELECT ...
If the table is being loaded into multiple partitions, the serial values are incremented in the same sequence as the table fragments.
Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]