mahara-contributors team mailing list archive
-
mahara-contributors team
-
Mailing list archive
-
Message #22275
[Bug 1353069] Re: db_format_tsfield() returning time value with offset on POstgres
Attaching a test script to help with troubleshooting time issues. It
models the entire lifecycle of a timestamp in Mahara:
1. Epoch fetch from time()
2. Converted to a date-time string by db_format_timestamp()
3. Stored into the DB as a timestamp without timezone
4. Retrieved from the DB as an epoch
5. Converted into a human-readable string with strftime()
** Attachment added: "A script to"
https://bugs.launchpad.net/mahara/+bug/1353069/+attachment/4258722/+files/timetest.php
--
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it!
https://bugs.launchpad.net/bugs/1353069
Title:
db_format_tsfield() returning time value with offset on POstgres
Status in Mahara ePortfolio:
In Progress
Status in Mahara 1.10 series:
In Progress
Status in Mahara 1.8 series:
In Progress
Status in Mahara 1.9 series:
In Progress
Status in Mahara 15.04 series:
In Progress
Bug description:
On postgres db_format_tsfield() calculates time by doing
FLOOR(EXTRACT(EPOCH FROM {$field})) which apparently doesn't make
sense if we are using fields without timezone (by reading this
http://postgresql.1045698.n5.nabble.com/Possible-problem-with-EXTRACT-
EPOCH-FROM-TIMESTAMP-td2125933.html).
To manage notifications about this bug go to:
https://bugs.launchpad.net/mahara/+bug/1353069/+subscriptions
References