I have 3 Drop Down Lists and a search button. The Drop downs provide the search criteria. So, the values can be all, few or none of them. The T-sql stored procedure would be foll. Is it possible to write a linq for the same.
Select customerId, productId, supplierId
From Orders
Where ( customerId = @customerId Or @customerId IS NULL )
And ( productId = @productId Or @productId IS NULL )
And ( supplierId= @supplierId Or @supplierId IS NULL )
I'm using .Net 4.0, Entity data model