From 046713e00f4eab03bff2e479ee9efa2a9d5ce847 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Thu, 6 Mar 2008 13:33:38 +0000 Subject: [PATCH] temp. fixed problem introduced with last egw_db commit (db::f() not working with db::select()), thought I want to check how often that is used, as an only asociative fetchmod needs half the memory --- phpgwapi/inc/class.egw_db.inc.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/phpgwapi/inc/class.egw_db.inc.php b/phpgwapi/inc/class.egw_db.inc.php index 585b5cf7b7..e222834b40 100644 --- a/phpgwapi/inc/class.egw_db.inc.php +++ b/phpgwapi/inc/class.egw_db.inc.php @@ -1695,9 +1695,10 @@ class egw_db * @param string $join=null sql to do a join, added as is after the table-name, eg. ", table2 WHERE x=y" or * "LEFT JOIN table2 ON (x=y)", Note: there's no quoting done on $join! * @param array/bool $table_def use this table definition. If False, the table definition will be read from tables_baseline + * @param int $fetchmode=ADODB_FETCH_BOTH ADODB_FETCH_BOTH (default), ADODB_FETCH_ASSOC or ADODB_FETCH_NUM * @return ADORecordSet or false, if the query fails */ - function select($table,$cols,$where,$line,$file,$offset=False,$append='',$app=False,$num_rows=0,$join='',$table_def=False) + function select($table,$cols,$where,$line,$file,$offset=False,$append='',$app=False,$num_rows=0,$join='',$table_def=False,$fetchmode=ADODB_FETCH_BOTH) { if ($this->Debug) echo "

db::select('$table',".print_r($cols,True).",".print_r($where,True).",$line,$file,$offset,'$app',$num_rows,'$join')

\n"; @@ -1723,7 +1724,7 @@ class egw_db { return $sql; } - return $this->query($sql,$line,$file,$offset,$offset===False ? -1 : (int)$num_rows,false,ADODB_FETCH_ASSOC); + return $this->query($sql,$line,$file,$offset,$offset===False ? -1 : (int)$num_rows,false,$fetchmode); } /**