Add a column to a report that would get sum or count values from another table
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-29-2024 11:39 AM - edited 08-30-2024 02:16 PM
I am building a report and need help to include columns to show the sum or count from a different table.
For example, I have table-1 that lists all the students and the tutor class they are enrolled in. Table-2 tracks all the time spent in tutor classes. The custom column would show the sum of hours for each student in each tutor class.
Table-1:
Student-1 Math
Student-1 Writing
Student-2 Math
Table-2:
Student-1 Math 07.01.24 2 hr
Student-1 Math 08.10.24 2 hr
Student-1 Math 08.13.24 1 hr
Student-1 Writing 08.03.24 1 hr
Student-2 Math 07.03.24 1 hr
Student-2 Math 08.08.24 1 hr
Student-2 Math 08.18.24 2 hr
Report:
Name Class July24 August24
Student-1 Math 2 hr 3 hr
Student-1 Writing 0 1 hr
Student-2 Math 1 hr 3 hr
Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-30-2024 01:46 PM
I missed to include in my post to ask how do you add the columns that has the sum(hours) to the report.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-02-2024 08:15 AM
If you add one more field for table 2 - 'Month" (can be calculated based on the date field), you can achieve it with multi-pivot table report on top of table 2:
Rows: Name, Class
Column: Month
Aggregation - class duration