[dev] Implicit conversion of mysql TIMESTAMP type to Horde_Date

Sebastian Birnbach birnbacs at gmail.com
Mon Jan 7 22:16:32 UTC 2019


Yes, Mapper is acting up on timestamps with Rdo. I did a local fix, it has
been working for me ever since:
https://bugs.horde.org/ticket/14803

  Sebastian

Am Mo., 7. Jan. 2019 um 18:03 Uhr schrieb Ralf Lang <lang at b1-systems.de>:

>
> Am 07.01.19 um 16:25 schrieb Ralf Lang:
> > Hi,
> >
> > I am currently a little puzzled by either Horde_Db or Horde_Rdo
> > implicitly converting TIMESTAMP db fields to Horde_Date values.
> > Unfortunately, it has the wrong idea about the timezone of TIMESTAMP.
> >
> > A timestamp stored as 2018-05-16 04:00:00 is returned as 2018-05-16
> > 04:00:00 Europe/Berlin.
> >
> > The database time_zone is SYSTEM. The system timezone is UTC.
> >
> > To understand the issue better, I'd rather turn off the automatic
> > conversion and do the conversion to Horde_Date manually. Is there any
> > config for Horde_Db to govern this?
>
>
> Looks like it's this line:
>
> https://github.com/horde/Rdo/blob/5d16dda64ed249400b18ba4f62fcbcd3443d9d83/lib/Horde/Rdo/Mapper.php#L230
>
> For a hotfix in my local issue, I may overload mapFields (60 loc) in the
> derived Mapper. Still, I think assuming the backend data is always in
> the frontend's default timezone might not always be right.
>
> --
> dev mailing list
> Frequently Asked Questions: http://wiki.horde.org/FAQ
> To unsubscribe, mail: dev-unsubscribe at lists.horde.org
>


More information about the dev mailing list