I understand so and so....NH work with entities and not with fields. What you are looking for is something more like to what you can do with pure ADO.NET and pure SQL. >From the view you can receive a DTO but to update an entity you need and entity and not part of it. A feature request in case of dynamic-map is possible but something out of the scope of NH because....NH work with entities.
2009/5/14 Stuart <[email protected]> > > On May 13, 9:29 pm, Fabio Maulo <[email protected]> wrote: > > > > I don't understand something....you are using session.Save(...) but you > are > > looking for an update ? > > > > I agree with you: calling Save() doesn't make any sense. I think I am > actually calling Update() in my code and I just mis-typed here, but > I'll be sure to check it when I return to the code in the morning. > > That said, the Merge() functionality is my primary concern, I think. > > > btw each method need a real full state and not a partial state created on > > the fly. > > > > Okay, if that's the case then what I am encountering here is likely by > design and not really a bug. So where do I file a feature request? ;-) > > Joking aside, though, do you understand why I would like this > functionality? I really do think it would be a nice feature when it > comes to dynamic-map mode. In my application I dynamically create a > view (scaffold-like) comprised of the user-editable fields -- there's > no point in sending the 'system fields' to the view. When the user > posts the form with the edited values, I have MR create a dictionary > for me -- again, with just the user-editable fields (and the key, of > course). It feels like there should be a way for me to update the > persisted object with these new values without having to flesh out the > whole record. If only you could see how nicely it would fit into my > current project! :) > > > If you want some special behavior you should configure your custom > tuplizer > > at least for EntityMode.Map. > > > > I think I will give this a shot. I know absolutely nothing about > tuplizers. Do you have any good references for me, or shall Google be > my guide? > > Thanks a lot for the help, Fabio. I really appreciate your work and > your help! > > > --Stuart > > > > -- 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 -~----------~----~----~----~------~----~------~--~---
