.Where (p => p.Category == session.Load<Category>(
categoryId)

Regards,

--
Mohamed Meligy
Senior Developer, Team Lead Backup (.Net Technologies - TDG - Applications)
Injazat Data Systems
P.O. Box: 8230 Abu Dhabi, UAE.

Phone:  +971 2 6992700
Direct:   +971 2 4045385
Mobile:  +971 50 2623624, +971 55 2017 621

E-mail: [email protected]
Weblog: http://weblogs.asp.net/meligy


On Tue, Jan 12, 2010 at 12:34 AM, ulu <[email protected]> wrote:

> Hi,
>
> What is the recommended way of using the new Linq provider? I'm using
> the trunk version and trying to do a simple thing: fetch entities by a
> foreign key.
>
> So, I've got the Product class and it has the Category property. How
> do I fetch all products given a categoryId?
> .Where (p => p.Category.Id == categoryId)
> or
> .Where (p => p.Category == session.Load<Category>(categoryId)
> ?
>
> Thanks
>
> ulu
>
> --
> 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.
>
>
>
>
--
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