Now, I'm reading source codes relating to DERBY-167. And I found next constructors. ColumnDescriptor(java.lang.String columnName, int columnPosition, DataTypeDescriptor columnType, DataValueDescriptor columnDefault, DefaultInfo columnDefaultInfo, TableDescriptor table, UUID defaultUUID, long autoincStart, long autoincInc, boolean autoinc) Constructor for a ColumnDescriptor ColumnDescriptor(java.lang.String columnName, int columnPosition, DataTypeDescriptor columnType, DataValueDescriptor columnDefault, DefaultInfo columnDefaultInfo, UUID uuid, UUID defaultUUID, long autoincStart, long autoincInc, boolean autoinc) Constructor for a ColumnDescriptor. These constroctors have many parameters. AutoIncrementing intial value is related to following parameters: long autoincStart, long autoincInc, boolean autoinc Default intial value is related to following parameter: DefaultInfo columnDefaultInfo I wonder how to handle these separated information of rules for initial values in DERBY-167 task .... New class InitialValueRule may be appropriate to exist .... Best regards. /* Tomohito Nakayama tomoihto@rose.zero.ad.jp tomonaka@basil.ocn.ne.jp Naka http://www5.ocn.ne.jp/~tomohito/TopPage.html */ ----- Original Message ----- From: "Kathey Marsden (JIRA)" To: Sent: Sunday, April 03, 2005 12:27 PM Subject: [jira] Commented: (DERBY-167) Inserting values in an identity column > [ > http://issues.apache.org/jira/browse/DERBY-167?page=comments#action_62039 > ] > > Kathey Marsden commented on DERBY-167: > -------------------------------------- > > Option 1 could be implemented per the sql standard by changing the > generated column-spec for CREATE TABLE from: > > generated-column-spec: > > [ [ WITH ] DEFAULT {ConstantExpression | NULL } > | > [ GENERATED ALWAYS AS IDENTITY > [ ( START WITH IntegerConstant > [ ,INCREMENT BY IntegerConstant] ) ] ] ] > > to > > [ [ WITH ] DEFAULT {ConstantExpression | NULL } > | > [ GENERATED [ALWAYS | BY DEFAULT ] AS IDENTITY > [ ( START WITH IntegerConstant > [ ,INCREMENT BY IntegerConstant] ) ] ] ] > > > > > >> Inserting values in an identity column >> -------------------------------------- >> >> Key: DERBY-167 >> URL: http://issues.apache.org/jira/browse/DERBY-167 >> Project: Derby >> Type: Improvement >> Components: SQL >> Versions: 10.1.0.0 >> Environment: SQL >> Reporter: Christian Rodriguez > >> >> It is not possible to insert a specific value in a column defined as >> identity. This makes it very hard to migrate from other RDBMSs or to >> import data dumped from other databases. >> For example, an autoincrement column in MySQL should be an identity >> column. The problem is that when the data is dumped from MySQL to a file, >> it generates inserts with values. These values cant be inserted in the >> Derby table. >> Posible solutions: 1. being able to "generate by default as identity" 2. >> being able to disable the "identity" feature for a column 3. being able >> to generate a column as non identity and after data is populated, alter >> table to add the "identity" to the column. > > -- > This message is automatically generated by JIRA. > - > If you think it was sent incorrectly contact one of the administrators: > http://issues.apache.org/jira/secure/Administrators.jspa > - > If you want more information on JIRA, or have a bug to report see: > http://www.atlassian.com/software/jira > > > > > -- > No virus found in this incoming message. > Checked by AVG Anti-Virus. > Version: 7.0.308 / Virus Database: 266.9.1 - Release Date: 2005/04/01 > > -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.9.3 - Release Date: 2005/04/05