Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Is table generator can shared?

 
Fu Dong Jia
Ranch Hand
Posts: 131
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If the different entities within the persistence unit can share the same table generator?
 
Tomaszz Lewandowski
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, the table for table generator has as many rows as the numer of entities that use it.
 
Ralph Jaus
Ranch Hand
Posts: 342
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I disagree with the statement
the table for table generator has as many rows as the numer of entities that use it.
The database table used for generating values has one row for each @GeneratorTable that uses it! This doesn't relate to the number of entities that use this @GeneratorTable (at least if the @GeneratorTable is used by more than one entity).
[ December 10, 2008: Message edited by: Ralph Jaus ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic