title: Grails - First Ten Values only in g:each
body: <pre><code>&lt;g:each in="${checking}" status="i" var="checking2"&gt;
  &lt;g:if test="${i&lt;10}" &gt;//Break The Loop&lt;/g:if&gt;
  //Do My Work Here
  &lt;/g:each&gt;
  </code></pre>
  
  <p>In above example, if its possible to get only first ten values from 'checking'. Suppose checking returns 100 values, I would like to access only first ten values. </p>
  
  <p>I know that is possible by using max:10 in controller and returning only 10 values in list, but I want as stated above.</p>
  
  <p>PS: I am new to this....</p>