If I have a team that's played 10 games, how would I create a report to show the overall stats for games 1-4 or games 3-6.

Statbook
2011-04-22 18:53

Here are the steps:

  1. Duplicate the "Overall (Last 5 Games)" report and select the duplicated report
  2. Go to the Reports -> Edit Reports... menu item (or just double-click the newly created report)
  3. For games 1 through 4, Replace the "Additional Instructions" field with the following text:

    WHERE s.gameID IN (SELECT g.id FROM games g ORDER BY g.gameNo LIMIT 0,4)  
    GROUP BY p.ID
     
  4. For games 3 through 6, Replace the "Additional Instructions" field with the following text:

    WHERE s.gameID IN (SELECT g.id FROM games g ORDER BY g.gameNo LIMIT 2,4)
    GROUP BY p.ID

NOTE: This is assuming the GameNo fields for the Games are consecutive and correctly named.

Average rating: 0 (0 Votes)

You cannot comment on this entry