#1575: query reset doesnt work
-------------------------+--------------------------------------------------
  Reporter:  tester      |       Owner:  jwage                
      Type:  defect      |      Status:  new                  
  Priority:  minor       |   Milestone:  1.0.4                
 Component:  Attributes  |     Version:  1.0.3                
Resolution:              |    Keywords:                       
  Has_test:  0           |    Mystatus:  Pending Core Response
 Has_patch:  0           |  
-------------------------+--------------------------------------------------
Old description:

> hi
>
> there is a problem when i try to reset a query for in the followig code
>
> $query = new Doctrine_Query();
> $cars = $query->select('c.*, RANDOM() rand')->from('Car
> c')->where('c.special_offer = ?',
> array(true))->orderBy('rand')->limit(5)->execute();
> $query->reset();
> $brands = $query->select('b.*')->from('Brand b')->where('b.disabled = ?
> or b.disabled IS NULL', array(false))->execute();
>

> i get the following exception:
> Unknown aggregate alias: rand
>
> also the limit needs to be reseted
>
> thanx

New description:

 hi

 there is a problem when i try to reset a query for in the followig code

 {{{
 $query = new Doctrine_Query();
 $cars = $query->select('c.*, RANDOM() rand')->from('Car
 c')->where('c.special_offer = ?',
 array(true))->orderBy('rand')->limit(5)->execute();
 $query->reset();
 $brands = $query->select('b.*')->from('Brand b')->where('b.disabled = ? or
 b.disabled IS NULL', array(false))->execute();
 }}}

 i get the following exception:
 Unknown aggregate alias: rand

 also the limit needs to be reseted

 thanx

-- 
Ticket URL: <http://trac.doctrine-project.org/ticket/1575#comment:3>
Doctrine <http://www.phpdoctrine.org>
PHP Doctrine Object Relational Mapper
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"doctrine-svn" group.
 To post to this group, send email to [email protected]
 To unsubscribe from this group, send email to [EMAIL PROTECTED]
 For more options, visit this group at 
http://groups.google.co.uk/group/doctrine-svn?hl=en-GB
-~----------~----~----~----~------~----~------~--~---

Reply via email to