P
powpowqueen
Hi I have just started using IQueryable and have a question that is a
little more complicated than any examples i can find
Can anyone answer my problem?
I have a 2 classess
Product and Colour
A product has a stock count.
a product has one colour
a colour has many products.
I have a IQueryable<Colour> object and would like to write the Where
criteria on this to get
All colours that have a product with stock >= 50.
Any ideas?
I know that if i was doing this in reverse using IQueryable<Product> i
would write
..Where(e => e.Stock >= stock)
and then get the colour property.
But i really want to be able to do this from the iqueryable collection
of Colours
Thanks in advance
little more complicated than any examples i can find
Can anyone answer my problem?
I have a 2 classess
Product and Colour
A product has a stock count.
a product has one colour
a colour has many products.
I have a IQueryable<Colour> object and would like to write the Where
criteria on this to get
All colours that have a product with stock >= 50.
Any ideas?
I know that if i was doing this in reverse using IQueryable<Product> i
would write
..Where(e => e.Stock >= stock)
and then get the colour property.
But i really want to be able to do this from the iqueryable collection
of Colours
Thanks in advance