Can the primary key in the entity bean be a Java primitive
type such as int?

Answer Posted / kameshwar

The primary key can't be a primitive type--use the
primitive wrapper classes, instead. For example, you can use
java.lang.Integer as the primary key class, but not int (it
has to be a class, not a primitive)

Is This Answer Correct ?    5 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Enlist the enterprise beans types?

607


Is microservice stateless?

497


Explain what is an EJB Context?

617


What is Enterprise JavaBeans Query Language (EJB QL)?

544


Why is ejb needed?

508






What is ejb and its types?

517


How do I use a less than or greater than on a message selector in ejb-jar.xml?

530


What are the attributes of transaction in ejb?

509


Which is more beneficial: Stateful or Stateless Bean?

582


Differentiate “find a method” from “select method” in EJB ?

532


What is ejb framework?

563


What is ejb container?

681


What is an entity manager?

534


What is ejb in java?

540


Write the basic requirement of a cmp entity based class in 2.0 from ejb 1.1?

595