Uploaded image for project: 'Plugins'
  1. Plugins
  2. CONTRIB-4804

Results returns wrong year (1969)

XMLWordPrintable

    • 2013062400
    • MOODLE_25_STABLE

      Hello,

      We have a query which works fine on 2.2.4+ and returns the right date. However, when we upgraded to 2.5.2, the date is incorrect... always 1969-12-31 16:33:32

      the timezone is correct. It works on 2.2.4+ but not our 2.5.2+ version

      Here is the query

      Select FROM_UNIXTIME(time, '%Y-%m-%d') AS 'Date', COUNT(FROM_UNIXTIME(time, '%Y-%m-%d')) AS 'Count'
      From prefix_log
      WHERE action= "login"
      AND userid <>"123456"
      GROUP BY FROM_UNIXTIME(time, '%Y-%m-%d')

      Returns as:...

      date count
      1969-12-31 16:33:32 157
      1969-12-31 16:33:32 500
      1969-12-31 16:33:32 541
      1969-12-31 16:33:32 752
      1969-12-31 16:33:32 755
      1969-12-31 16:33:32 709
      1969-12-31 16:33:32 489
      .....

      weird ...

            timhunt Tim Hunt
            moodlevcc Lawrence N
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.