title: Linq - SQL passing parameters into GroupBy()
body: <p>Using a linq query, how can i pass parameters into the groupby function? Depend on user selection, it will be grouped differently</p>
  
  <pre><code> var query = (from to in OrderQuery
                       group to by to.FromDateUtc into groupedDate
                       let grouped = groupedDate.GroupBy(o =&gt; o.Name)
  </code></pre>
  
  <p>I would like to pass different groupby values. Any idea?</p>
  
  <p>Cheers</p>