On Sep 22, 4:53 pm, Scott <[email protected]> wrote: > So it looks like I should only be using in memory in the where clause
no. you don't do in memory operations anywhere except a) in the final select, or b) in a situation where the operation can be evaluated while SQL is generated (in LINQ generally, don't know if NH supports that) you can use in-memory objects as parameters though. > But what do I do in a situation like this: > > List<Item> items = FromMemory(); > > var result = (from i in items > join a in NHSession.Linq<attributeA>() on i.attributeA equals a > select a); again, try the two variations i've shown, but pass the items you actually need: var items = FromMemory().Select (i => i.attribute>); you could to do that Select() inline in the query. again, this depends on the provider (re-linq handles this, so NH should too) > I'm joining on a property of the object, do I always need to make my > own IEqualityComparer? comparers work in memory only. -- 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.
