O'Reilly logo

Special Edition Using Enterprise JavaBeans™ 2.0 by Brian Keeton, Chuck Cavaness

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Defining the Primary Key Class

An entity object must have an associated primary key object. This isn’t surprising given that an entity bean instance typically corresponds to a row in a relational database table. Even if you’re using an entity bean to represent some other type of data, you still have to associate a primary key with each unique element of that data so the container can keep track of everything. Part of your job as a bean provider is to identify the primary key class for an entity bean within its deployment descriptor. This is true no matter which persistence management approach you choose.

Note

This section isn’t intended to imply that all the data associated with an entity bean comes from a single table in a database. More often, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required