title: Mysql rand() function in Zend framework 2
body: <p>In <strong>zend framework 1</strong>, we had used mysql <strong>rand()</strong> function like below or using <strong>zend_db_expr()</strong>. I have tried this in <strong>ZF2</strong>, but this is not working. Somebody please help me to use this in <strong>Zend Framework 2</strong></p>
  
  <pre><code>$select = $this-&gt;db()-&gt;select()
          -&gt;from('TABLE')
          -&gt;order('RAND()');
  </code></pre>
  
  <p>Thanks,</p>