Ticket modified by Klaus Leithoff at 2011/08/22 16:16:
Tracking System: Bugs
Category: API
Version: Trunk
Status: Open
Resolution: None
Completed: 0%
Priority: 5 - medium
Created by: Anthony Messina
Created on: 2011/05/14 17:54
Assigned to: Klaus Leithoff, Ralf Becker
Summary: #2962 - PostgreSQL error beginning at r34914
Invalid SQL: SELECT COUNT() FROM egw_categories WHERE cat_owner=0:
ERROR: operator does not exist: character varying = integer
LINE 1: SELECT COUNT() FROM egw_categories WHERE cat_owner=0
^
HINT: No operator matches the given name and argument type(s). You
might need to add explicit type casts.
The offending lines seem to be:
phpgwapi/inc/class.categories.inc.php:896: if
(!$GLOBALS[‘egw’]->db->select(self::TABLE,‘COUNT(*)’,‘cat_owner=0’,LINE,FILE)->fetchColumn())
phpgwapi/inc/class.categories.inc.php:898:
$GLOBALS[‘egw’]->db->update(self::TABLE,‘cat_owner=0’,"(cat_owner=-1 OR
cat_appname=‘phpgw’)",LINE,FILE);
Temporarily, modifying ‘cat_owner=0’ to ‘cat_owner::int=0’ solves the
problem, though it appears that the long term goal is to support
multiple numbers in the cat_owner field. This method won’t work for that.
Linked entries:
https://community.egroupware.org/egroupware/index.php?menuaction=tracker.tracker_ui.edit&tr_id=2962&no_popup=1