Jump to content

Add "GROUP BY" to simple_construct method


Guest marcele

Recommended Posts

Posted

Just a suggestion .. sometimes I want to use 'GROUP BY' in a simple_select .. it seems like it is missing from the IPS DB Driver..

eg

$this->ipsclass->DB->simple_construct( array(

'select'	=> 'f.foo, COUNT(*) AS some_count',

'from'		=> array('foo => 'f'),

'add_join'	=> array(


0 => array(

'from'	  => array( 'bar' => 'b' ),

'where'	 => 'f.id = b.id',

'type'	  => 'left'

)),


'group'	 => 'f.foo',

'order'	 => 'f.foo ASC'

));

Posted

I second this, I project I just finished I had to fall back on $this->ipsclass->DB->query(); twice because of the lack of group by support in the driver.

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...