title: Lambda Expression Search
body: <p>I want to perform the equivalent of a 'dynamic SQL' search for a product with variable search criteria, but in C# code. For example, a product is defined like this:</p>
  
  <pre><code>class Product
  {
    public decimal Price { get; set; }
    public int Quantity { get; set; }
  }
  </code></pre>
  
  <p>My search control has a textbox for price and a textbox for quantity. If the user specifies something, it should be included in the search (otherwise not). In reality, my product has many more than 2 properties.</p>
  
  <p>How can I build a lambda expression generically based on any such search by variable criteria?</p>
  
  <p>Thanks!</p>