# Primary Key Generation

Use the Primary Key Generation area in the JPA Details view to specify how to generate a primary key for a given entity.

Property | Description | Default | Available for Entity Type
--- | --- | --- | ---
Table Generator | These fields define the database table used for generating the primary key and correspond to the `@TableGenerator` annotation. |  | Entity
Name | Unique name of the generator. |  | Entity
Table | Database table that stores the generated ID values. |  | Entity
Schema | Database schema of the Table. |  | Entity
Catalog | Database catalog of the Table. |  | Entity
Primary key column | The column in the table generator's Table that contains the primary key. |  | Entity
Value column | The column that stores the generated ID values. |  | Entity
Allocation size | The value for the Primary Key Column in the generator table. | 50 | Entity
Initial value | The starting value of the generated primary key. | 0 | Entity
Sequence Generator | These fields define the specific sequence used for generating the primary key and correspond to the `@SequenceGenerator` annotation. These fields apply only when Strategy = Sequence. |  | Entity
Name | Name of the sequence table to use for defining primary key values. |  | Entity
Sequence | Unique name of the sequence. |  | Entity
Schema | Database schema of the Sequence. |  | Entity
Catalog | Database catalog of the Sequence. |  | Entity
Allocation size | These fields define the specific sequence used for generating the primary key and correspond to the `@SequenceGenerator` annotation. These fields apply only when Strategy = Sequence. | 50 | Entity
Initial value | The starting value of the generated primary key. | 1 | Entity

Related reference

- JPA Details view (for entities)