Crystal clear to me :)

I try to exlain in some other way,,,

I've got this classes (C#)

public class User{
   public string UserId{ get; set; }
   public IList<Item> Items{ get; set; }
}
public class Item{
    public int ID{ get; set; }
}

The property UserId is mapped as ID in the mappingfile.

if I do like session.Get<User>("Jan") i get the user object returned
and the items collections i populated
If i fo session.Get<User>("jan") i also get the user object returned
(the same entity) but the items collections is empty

Since to me the User Jan and the user jan are the same entities this
is a problem. I want Get<User> to return the same way regardless of
the case of the userId property.

On Dec 18, 1:00 pm, "Fabio Maulo" <[email protected]> wrote:
> What ?
>
> 2008/12/18 [email protected] <[email protected]>
>
>
>
> > Hi!
>
> > I've ran into a problem with NHibernate 2.0. I've got an user entity
> > with its userID as Id. The ID is not case sensitive when creating the
> > instance of the object. To the user i have a collection mapped as a
> > bag - and if the userid is given as the foreign key then the
> > collection is populated if not the collection is empty.... I can not
> > see a solution?
>
> --
> Fabio Maulo
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to