[ http://jira.nhibernate.org/browse/NH-364?page=all ]
Sergey Koshcheyev updated NH-364:
---------------------------------
Fix Version: LATER
Version: 1.2.0.Beta2
> IdBag doesn't work with Identity columns
> ----------------------------------------
>
> Key: NH-364
> URL: http://jira.nhibernate.org/browse/NH-364
> Project: NHibernate
> Type: Improvement
> Components: Core
> Versions: 1.2.0.Beta2, beta-0.9.1
> Reporter: Paul Hatcher
> Priority: Minor
> Fix For: LATER
>
> Take two classes Link and Category and give Link an IList of Categories. Map this as an idbag and make the generator of the collection-id be identity.
> It saves the Link and Category objects correctly, but gives a casting exception on saving CategoryLink.
> Looking at the code, BasicCollectionPersister is used and during GenerateInsertRowString this takes no account of the fact that we have an IdentifierBag collection and that there might be an identity column.
> The 2.1 java code exhibits the same problem, so I don't quite get how this should work. I've included a test case against the bug number in the test project.
> I could have done something wrong here, but then the docs need fixing :-)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.nhibernate.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
|