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

Forum posts are counted twice in Statistics

    XMLWordPrintable

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 3.7.5
    • None
    • Forum
    • None
    • MOODLE_37_STABLE

    Description

      Viewing stats for a user (Home > Courses > [course] > Reports > Statistics) shows double the number of forum posts as they have actually made, as shown in:

      • the student outline report (Home > Courses > [course] > Participants > teststudent1 test > Reports > Outline report), and
      • the course logs (Home > Courses > [course] > Reports > Logs)

      This seems to be because posts are logged as two events:

      1. "Some content has been posted.
      2. "{Discussion,Post} created"

      The statistics pages present the two events as if they were separate posts.

       

      I guess a fix for this would be in lib/statslib.php, filtering out one of those two event types when compiling the stats to the stats_user_{daily,weekly,monthly} tables.

       

      Attached screenshots illustrate stats page with 2x posts compared to logs and student outline.

      Attachments

        1. logs.png
          logs.png
          107 kB
        2. outline.png
          outline.png
          9 kB
        3. stats.png
          stats.png
          19 kB

        Activity

          People

            Unassigned Unassigned
            balchd Dave Balch
            Adrian Greeve, Andrew Lyons, Huong Nguyen, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze, Stevani Andolo
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: