[Tickets #1482] NEW: Viewing calendar broken with postgres & non-ISO
date format - with fix
bugs at bugs.horde.org
bugs at bugs.horde.org
Thu Mar 3 14:35:18 PST 2005
DO NOT REPLY TO THIS MESSAGE. THIS EMAIL ADDRESS IS NOT MONITORED.
Ticket URL: http://bugs.horde.org/ticket/?id=1482
-----------------------------------------------------------------------
Ticket | 1482
Created By | oliver at gtwebmarque.com
Summary | Viewing calendar broken with postgres & non-ISO date format - with fix
Queue | Kronolith
Version | 2.0.2
State | Unconfirmed
Priority | 1. Low
Type | Bug
Owners |
-----------------------------------------------------------------------
oliver at gtwebmarque.com (2005-03-03 14:35) wrote:
If using a postgresql database with the datestyle set to a non-default value
(mine is 'SQL, DMY' for UK format dates), no events will show up on the
calendar.
This is because SQL queries are composed in the ISO format YYYY-MM-DD.
To fix this, in kronolith/lib/Driver/sql.php, after lines 493-502 (case
'oci8': ... break;) add the following extra case for postgres:
case 'pgsql':
$query = "SET datestyle TO 'iso'";
/* Log the query at a DEBUG log level. */
Horde::logMessage(sprintf('SQL session setup by %s: query =
"%s"',
Auth::getAuth(), $query),
__FILE__, __LINE__, PEAR_LOG_DEBUG);
$this->_db->query($query);
break;
More information about the bugs
mailing list