From 25ba714000a4d3e5065350ed267d11278f62b8c0 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Sat, 7 Aug 2004 12:10:12 +0000 Subject: [PATCH] not using distinct on MaxDB too --- infolog/inc/class.soinfolog.inc.php | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/infolog/inc/class.soinfolog.inc.php b/infolog/inc/class.soinfolog.inc.php index 57f0abe8b5..9fc704b33b 100644 --- a/infolog/inc/class.soinfolog.inc.php +++ b/infolog/inc/class.soinfolog.inc.php @@ -552,8 +552,17 @@ if ($action == '' || $action == 'sp' || count($links)) { $sql_query = "FROM phpgw_infolog $join WHERE ($filtermethod $pid $sql_query) $link_extra"; - // mssql cant use DISTICT of text columns (info_des) are involved - $distinct = $this->db->Type != 'mssql' ? 'DISTINCT' : ''; + switch($this->db->Type) + { + // mssql and others cant use DISTICT of text columns (info_des) are involved + case 'mssql': + case 'sapdb': + case 'maxdb': + $distinct = ''; + break; + default: + $distinct = 'DISTINCT'; + } $this->db->query($sql="SELECT $distinct phpgw_infolog.info_id ".$sql_query,__LINE__,__FILE__); $query['total'] = $this->db->num_rows();