#755187 php-horde-kronolith: sync with syncevolution fails with SQL syntax error

#755187#5
Date:
2014-07-18 15:22:55 UTC
From:
To:
After upgrading php-horde-kronolith from 4.1.5-1 to 4.2.0~beta2-1, I'm
no longer able to synchronize calendar with my phone using syncevolution
client. New events created on my phone end up in kronolith nicely, but
events created in kronolith will not end up in my phone.

The horde5.log has lots of lines like this:
014-07-18T18:15:05+03:00 ERR: HORDE [kronolith] SQL QUERY FAILED:
SQLSTATE[42000]: Syntax error or access violation: 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 ' , , , , , , , , , , , , , , , , , , , , , , , , , ,
 , , , , , , , , , , , , , )' at line 1
          SELECT event_id, event_uid, calendar_id, event_description,
                 event_location, event_private, event_status,
                 event_attendees,
                 event_title, event_recurcount, event_url,
                 event_timezone,
                 event_recurtype,
                 event_recurenddate,
                 event_recurinterval,
                 event_recurdays,
                 event_start,
                 event_end,
                 event_allday,
                 event_alarm,
                 event_alarm_methods, event_modified, event_exceptions,
                 event_creator_id, event_resources, event_baseid,
                 event_exceptionoriginaldate FROM kronolith_events WHERE event_uid =
                 '20111002151119.88304193jgdku0ao@www.nummela.org' AND calendar_id IN
                 (, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
                 , , , , , ) [pid 8877 on line 204 of "/usr/share/php/Horde/Db/Adapter/Pdo/Base.php"]

I believe there is one such line for each of my events.

#755187#10
Date:
2014-08-08 07:05:17 UTC
From:
To:
I don't have time and/or motivation to create a proper fix for this. I
did create a workaround though: in
/usr/share/horde/kronolith/lib/Driver/Sql.php function getByUID() I
just commented out the "Optionally filter by calender" part. Now, this
obviously breaks filtering by calendar, but I only use one calendar
anyway so that's not a problem for me.

For a real fix, it should be investigated why the $calendars ends up
being a list of commas and spaces.

#755187#15
Date:
2014-08-08 15:10:45 UTC
From:
To:
2014-08-08 9:05 GMT+02:00 Ville Nummela <ville@nummela.org>:
Can you report this bug upstream?

NB: I also recently uploaded a bunch of updates to sid. This /may/
solve the problem.

Regards