Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-19775

Stupid SQL in stats

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Duplicate
    • 2.0
    • None
    • Course
    • None
    • MOODLE_20_STABLE

    Description

      Presumably when it says

      $DB->get_field_sql('SELECT timeend FROM

      {stats_user_daily} ORDER BY timeend');

      It means

      $DB->get_field_sql('SELECT MIN(timeend) FROM {stats_user_daily}

      ');

      The attached patch fixes this. I guess the fix needs to be backported to 1.9 though.

      Also, I don't think "Sorry, there is no available data to display" should be a print_error. It should be a nicer message than that. I have not fixed that.

      Attachments

        Issue Links

          Activity

            People

              poltawski Dan Poltawski
              timhunt Tim Hunt
              Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Ilya Tregubov, Sara Arjona (@sarjona)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: