[kronolith] Mysql DB Syntax Error

Chuck Hagenbuch chuck at horde.org
Tue Aug 5 21:13:15 UTC 2008


Quoting Tyler Giddings <tgiddings at us.cyberscience.com>:

> I noticed the following error in the logs:
>
>> Aug 05 08:07:58 HORDE [error] [kronolith] DB Error: syntax error:  
>> SELECT event_id, event_uid, calendar_id, event_description,  
>> event_location, event_private, event_status, event_attendees,  
>> event_keywords, event_title, event_category, event_recurcount,  
>> event_recurtype, event_recurenddate, event_recurinterval,  
>> event_recurdays, event_start, event_end, event_alarm,  
>> event_modified, event_exceptions, event_creator_id FROM  
>> kronolith_events WHERE event_uid = ? AND calendar_id IN (?)  
>> [nativecode=1064 ** You have an error in your SQL syntax; check the  
>> manual that corresponds to your MySQL server version for the right  
>> syntax to use near '? AND calendar_id IN (?)' at line 1] [pid 5923  
>> on line 431 of "/usr/share/horde3/kronolith/lib/Driver/sql.php"]
>> Aug 05 08:07:58 HORDE [error] [kronolith] DB Error: syntax error:  
>> SELECT event_id, event_uid, calendar_id, event_description,  
>> event_location, event_private, event_status, event_attendees,  
>> event_keywords, event_title, event_category, event_recurcount,  
>> event_recurtype, event_recurenddate, event_recurinterval,  
>> event_recurdays, event_start, event_end, event_alarm,  
>> event_modified, event_exceptions, event_creator_id FROM  
>> kronolith_events WHERE event_uid = ? AND calendar_id IN (?)  
>> [nativecode=1064 ** You have an error in your SQL syntax; check the  
>> manual that corresponds to your MySQL server version for the right  
>> syntax to use near '? AND calendar_id IN (?)' at line 1] [pid 5923  
>> on line 431 of "/usr/share/horde3/kronolith/lib/Driver/sql.php"]
>
> I ran the SQL command directly but removed the WHERE clause and the  
> sql worked fine. My configuration for Kronolith is using the SQL  
> driver with Horde Defaults. The horde configuration is using the  
> MySQLi driver.

You'll need to log the values for the query (the ones substituted for  
the ? placeholders). Most likely the array of calendars is empty, so  
it's generating an empty IN() clause.

-chuck


More information about the kronolith mailing list