I'm attempting to convert my data access layer from using primarily
datasets to nHibernate and I've run into a hurdle.

We have many cases where the result set does not map to a business
object such as the following SQL statement:

SELECT Row_Number() OVER (ORDER BY
ContentCode,ItemNumber,ItemRevisionLevel) as RowNumber,
RecordID,Row_Number() OVER (ORDER BY
ContentCode,ItemNumber,ItemRevisionLevel) as Position from Items where
ty...@examtype

It is easy to make a business object for "Item" which is great.  But I
have no idea how to tell nHibernate to return the RowNumber and
Position fields in this query.

Also rather then retrieving all 50 fields from my Items table, is it
possible to tell nHibernate to just return the three fields
(RowNumber, RecordID, and Position) as shown in the above query?

How?

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