Arrow_left   Arrow_right
 
  #42

IgnitedQuery::select fails when columns are not supplied

    • Created on: Tue, 19 May 2009 (over 2 years ago)
    • Reported by: Stan Angeloff
    • Assigned to: -
    • Milestone: 1.0
    • Status: Fixed
    • Priority: High (2)
    • Component: -
    The following code:

    		// reset select if it is the default "*"
    		if(is_string($this->q_select))
    		{
    			$this->q_select = array();
    		}


    Should be moved above this if block:

    		if($cols === false)
    		{
    			$obj = new IgnitedQuery();
    			$obj->q_parent =& $this;
    			$this->q_select[] =& $obj;
    			return $obj;
    		}


    to ensure q_select is a valid array. The current implementation throws a PHP warning and is unusable.

    Cheers,
    Stan
  • Followers
     
    Ico-users Stan Angeloff 
     
    Attachments
    No attachments
    Associations
     
    No associations
    Activity
     
    User picture

          on May 19, 2009 @ 09:45PM UTC * By m4rw3r

    Status changed from New to Fixed
    (In revision:279) Fixes #42, #43, #44 and #45
    Thanks for spotting those Stan!
    Time Expenditure
    Loading