//DB_DataObject::debugLevel(1);
$this->_extra_cols = array('qty' );
$this->selectAdd("count($tn.id) as qty");
+ $this->selectAdd("count( distinct $tn.on_id) as uqty");
$this->whereAdd('LENGTH(join_person_id_id.name) > 0 ');
$this->groupBy('person_id');
}
//DB_DataObject::debugLevel(1);
$this->_extra_cols = array('qty' , 'uqty');
$this->selectAdd("count($tn.id) as qty");
- $this->selectAdd("count( distinct $tn.on_id) as uqty");
+ $this->selectAdd("count( distinct $tn.on_table, $tn.on_id) as uqty");
$this->groupBy('on_table');
}