Home »
MCQs »
JPA MCQs
Which of the following annotations is used to indicate an entity's primary key field?
10. Which of the following annotations is used to indicate an entity's primary key field?
- @pk
- @primary
- @key
- @id
Answer: D) @id
Explanation:
@id annotation is used to specify the primary key field of an entity.