-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: Mapping file without hava id property
PostPosted: Thu Dec 31, 2009 12:55 am 
Newbie

Joined: Thu Aug 27, 2009 6:28 am
Posts: 19
Hi Guys,
I was tried to map the table without having an primary key, I got an error like"property is invalid in the mapping file. expected id property".
Then I tried with creating id property and i am not specified the column, even though I cannot proceed ... I caught up with an error " System.IndexOutOfRangeException: Index was outside the bounds of the array." and in the inner exception "Initialization of object failed : Could not compile the mapping document"

Is there any samples to create mapping without primarykey?

Thanks & Regards,
Nizam

_________________
Thanks & Regards
Nizam Abdul


Top
 Profile  
 
 Post subject: Re: Mapping file without hava id property
PostPosted: Thu Jan 07, 2010 3:30 am 
Expert
Expert

Joined: Thu Dec 14, 2006 5:57 am
Posts: 1185
Location: Zurich, Switzerland
No, because NHibernate depends on an identity property and a corresponding primary key.

_________________
--Wolfgang


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.