I have a table with 2 fields : School Name; Student ID.
I want to randomly display a predetermined number of Student ID per school.
For example, 2 random Student IDs from School A; 3 random Student IDs from School B.
I would also like the query to know how many random records (Student Ids) to generate, based on another query or table (School A: 2 records; School B: 3 records; School C: 1 record, etc.)
Ultimately, those will be shown in a report. 1 page per School Name, with the randomly selected student IDs underneath the School Name.
So far, I've only been able to generate Student IDs randomly, but I can't tell the query to generate those for each school.
The two links below show an example of the original table, and how I would like the report to look like.
Any help would be greatly appreciated!