nerdexam
Oracle

1Z0-860 · Question #37

A developer is creating an entity which is mapped to a table that has a primary key constraint defined on two character columns and would like to use mapping defaults as much as possible to simplify…

The correct answer is C. Use a separate @Embeddable class to map those two columns and use an @Embeddedld annotation E. Use a separate class to map those two columns. Specify that class using @ldClass annotation on the. See the full explanation below for the reasoning.

Question

A developer is creating an entity which is mapped to a table that has a primary key constraint defined on two character columns and would like to use mapping defaults as much as possible to simplify the code Which two mapping options can be chosen? (Choose two.)

Options

  • AUse an @ld property that constructs a private field as a concatenation of two columns.
  • BUse a separate class to map those two columns and use an @ldClass annotation to denote the primary
  • CUse a separate @Embeddable class to map those two columns and use an @Embeddedld annotation
  • DUse a separate @Embeddable class to map those two columns and add two fields or properties to the
  • EUse a separate class to map those two columns. Specify that class using @ldClass annotation on the

How the community answered

(49 responses)
  • A
    6% (3)
  • B
    2% (1)
  • C
    82% (40)
  • D
    10% (5)

Community Discussion

No community discussion yet for this question.

Full 1Z0-860 Practice