title: Rendering coure sql statement to linq equivalent
body: <p>Can anyone help me convert my sql statement yo linq query
  Sql query:</p>
  
  <pre><code>select
         MIN(a.StockCode) AS StockCode,
         MIN(a.Qty) AS Qty,
         MIN(a.TotalAmt) AS TotalAmt,
         MIN(a.DateAlloted)AS DateAlloted,
         MIN(a.Buy_Sold_Ind) AS Buy_Sold_Ind,
         convert(bit, min(convert(int, a.Posted))) AS Posted,
         convert(bit, min(convert(int, a.Reversed))) AS Reversed,   
         MIN(a.CustAID) AS CustAID 
  from Stkb_Sold a
  group by a.StockCode
  order by count(a.StockCode) DESC
  </code></pre>