Hibernate: table without primary key

This is a discussion on Hibernate: table without primary key within the JDBC JAVA forums in Framework and Interface Programming category; Hi, Is there a possibility in Hibernate to create a table without a primary key (without the @Id annotation)? I set up a with a dummy key, but I hate this solution. Thanx Andre...

Go Back   Application Development Forum > Framework and Interface Programming > JDBC JAVA

Object Mix

Register FAQ Calendar Search Today's Posts Mark Forums Read
  #1  
Old 01-18-2008, 08:30 AM
Andre Rothe
Guest
 
Default Hibernate: table without primary key

Hi,

Is there a possibility in Hibernate to create a table without a primary
key (without the @Id annotation)? I set up a with a dummy key, but I
hate this solution.

Thanx
Andre
Reply With Quote
  #2  
Old 02-10-2008, 03:53 PM
Avinash Ramana
Guest
 
Default Re: Hibernate: table without primary key

On Jan 18, 8:30 am, Andre Rothe <andre.ro...@imise.uni-leipzig.de>
wrote:
> Hi,
>
> Is there a possibility in Hibernate to create a table without a primary
> key (without the @Id annotation)? I set up a with a dummy key, but I
> hate this solution.
>
> Thanx
> Andre


No. Hibernate uses the primary key as a method of keeping identity.
Dummy key is fine


-Avinash
Reply With Quote
Reply


Thread Tools
Display Modes


All times are GMT -5. The time now is 07:55 PM.


Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
vB Ad Management by =RedTyger=

In an effort to better serve ads to our visitors, cookies are used on objectmix.com. For more information, check out our Privacy Policy.