. */ /** * Doctrine_Query_Orderby_TestCase * * @package Doctrine * @author Konsta Vesterinen * @license http://www.opensource.org/licenses/lgpl-license.php LGPL * @category Object Relational Mapping * @link www.phpdoctrine.com * @since 1.0 * @version $Revision$ */ class Doctrine_Query_Orderby_TestCase extends Doctrine_UnitTestCase { public function testOrderByAggregateValueIsSupported() { $q = new Doctrine_Query(); $q->select('u.name, COUNT(p.phonenumber) count') ->from('User u')->leftJoin('u.Phonenumber p') ->orderby('count DESC'); $users = $q->execute(); } }