Hi,
I spent quite few bits investigating this...:
http://jira.nhibernate.org/browse/NH-1574

And it seems there's the same core issue to that. I will put together
an unit test to figure this out (when I find time this evening)...

But just quickly from what I remember in
PocoEntityTuplizer.BuildProxyFactory the idGetters and IdSetters seem
to be not resolved properly (and thus passing nulls to the proxy
factory)... If that will help anyone who will get to it before
me... ;-)

Cheers,
Jarda



On Nov 18, 3:06 pm, "Fabio Maulo" <[EMAIL PROTECTED]> wrote:
> where you don't have the ID?How you are checking it ?
> Do you can send some UnitTest code-lines ?
>
> 2008/11/18 mattcole <[EMAIL PROTECTED]>
>
>
>
>
>
> > Hi,
> > I have a couple of classes that are associated, the relevant mapping
> > bits are like so:
>
> > <class name="Person" table="Person">
> >    <id name="Id" access="nosetter.camelcase-underscore"
> >      column="PersonId" type="Int32">
> >      <generator class="identity" />
> >    </id>
> >   ...
> >    <many-to-one name="ProcessSet" access="property"
> > column="ProcessSetId" />
> >  </class>
> > <class name="ProcessSet" table="ProcessSet">
> >    <id name="Id" access="nosetter.camelcase-underscore"
> >      column="ProcessSetId" type="Int32">
> >      <generator class="identity" />
> >    </id>
> >    ...
> >  </class>
>
> > with C# implementations like:
>
> >  public class Person : IAggregateRoot<int>, IPerson
> >    {
> >        private int _id = default(int);
> >        public ProcessSet ProcessSet { get; set; }
>
> > ...
> > }
>
> >  public class ProcessSet : IAggregateRoot<int>
> >    {
> >        private int _id;
> > ...
> > }
>
> > The problem I seem to be having, is that when I load a Person object,
> > I get a proxy object for the ProcessSet as expected as I haven't
> > disabled lazy-loading.  However, that proxy object has an Id of 0,
> > rather than it's actual Id.
>
> > Does anyone know why this is, and how I can make it load the Id?  From
> > the documentation, I thought that the Id was the only property that
> > should actually be loaded.
>
> > Thanks,
> > Matt
>
> --
> 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