Another option would be to create a view with the status field selected via 
subquery, then map db reads to that view and db writes to the table. A bit 
more complicated in the mapping but might be easier in the domain.

On Nov 2, 2008 6:31 AM, "Ken Egozi" <[EMAIL PROTECTED]> wrote:

I wanted to say that a subquery is what you might want to look for.

as I come from a strong SQL background, I usually go through the "let's 
think what kind of SQL I want NH to create" and it helps with constructing 
the correct Criterias or HQL.

and as for de-normalising the schema - if your app is doing more SELECTs on 
the status than INSERT into the history, then I'd say that addind Status 
field would prove itself as a good thing

On Sat, Nov 1, 2008 at 8:46 PM, Nathan Stott <[EMAIL PROTECTED]> wrote: > > 
> Thanks for the tip. ...

Ken Egozi. http://www.kenegozi.com/blog http://www.musicglue.com 
http://www.castleproject.org http:/...

--~--~---------~--~----~------------~-------~--~----~

You received this message because you are subscribed to the Google Groups 
"nhusers" group. To post...


--~--~---------~--~----~------------~-------~--~----~
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