• Post Reply Bookmark Topic Watch Topic
  • New Topic

Primary Key Class in CMP & BMP  RSS feed

 
Shrinivas Mujumdar
Ranch Hand
Posts: 328
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello
1> What is the use of Primary Key Class in CMP or BMP?

2> It is observed from my side that If Primary Key is a single field Primary Key then without putting a ".class" of primary key class in jar also EJB works fine.but for composite primary key i desperately required it?

Can anybody focus more on this?

Thanks in Advance

Shrinivas
 
Sebastian Hennebrueder
Ranch Hand
Posts: 49
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When I use a single field as primary key, I do not use a Primary key class.

As you stated, with a complex primary key (more than one field) you must use a primary key class.

You may alway use a primary key because
- design purpose (consistent use of pk classes or wanting to seperate primary key and fields used for primary key)
- auto - increment for some EJB containers when you want to use unknown pk

Regards Sebastian
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!