Just a piece of advice. You could have saved yourself a great deal of trouble by writing a 5 minute, very simple, NH ONLY, test to verify the mappings.
On Mar 18, 6:07 pm, SedulousTurtle <[email protected]> wrote: > *Solution Post* > It was truly a newbie mistake...stemming from not setting properties > to be "virtual". > > I hadn't declared any of my properties "virtual", except for the > string "Name" and a few other properties, which were virtual by > coincidence since I'm taking advantage of inheritance to implement > business logic. Therefore, the proxy couldn't override properties, > and their values couldn't be lazy initialized by NHibernate, even > though the proxies were going through the initialization process. > > Using unpacking, the actual objects were being manipulated, which > could be initialized properly, which is why the application worked > properly with unpacking. > > If any relatively new NHibernate users encounter a bug where your > proxy values are set to null or 0 even after initialization, or if > lazy loading is not working transparently, this may be indicative of > not setting properties "virtual". Many sources mention the need to > declare things as virtual, but I haven't found a place that mentions > the symptoms that indicate the issue. I don't think the users FAQ > (which includes common bugs) mentions the symptoms of this issue; > perhaps I'll go update it... > > *Kudos* > Thanks again to Fabio for persistent attention...and for the debugging > strategy you suggested. Your generous work for the NHibernate > community is inspiring; I'll look for an effective way that I can > contribute as well. > > On Mar 18, 11:30 am, Fabio Maulo <[email protected]> wrote: > > > Wold be interesting and useful to have the solution post in some where and a > > link in this thread (or the solution in this thread) > > > 2010/3/18 SedulousTurtle <[email protected]> > > > > Issue is resolved! I will post a wrap up with solution/proper thank > > > you's momentarily. Thanks! > > > > On Mar 17, 5:51 pm, Fabio Maulo <[email protected]> wrote: > > > > 2010/3/17 SedulousTurtle <[email protected]> > > > > > > Fabio, thank you for your persistent attention...though that last post > > > > > was a little unsettling. > > > > > But that was to let you know that you are taking the wrong way. > > > > The usage of SessionImp.PersistentContext is unusual even for extreme > > > > advanced users and you said that you are in the initial stage of your > > > > learning curve. > > > > > Your problem is in another place believe me. > > > > > IMO you should write a very simple test using 100% pure NH (read it as > > > > NH > > > > and your entities a nothing more). > > > > If you can't see your issue in this test you can be 1000% sure that your > > > > problem is in another place. > > > > > -- > > > > 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]<nhusers%[email protected]> > > > . > > > For more options, visit this group at > > >http://groups.google.com/group/nhusers?hl=en. > > > -- > > Fabio Maulo- Hide quoted text - > > > - Show quoted text - -- 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.
