title: Pagination through Sql query
body: <p>I am developing an application in which am using grid view. I want to use pagination for that grid view by using sql query.</p>
  
  <p>I want to display records with the help of <code>pagesize</code> and <code>pageindex</code>. </p>
  
  <p>How can I do this with sql query?</p>