JeffPeterson1
4 years agoQrew Captain
how to figure out # of child records by a value and create a ranked list
I have 2 tables Sites(parent) and Site Visits(child).
Each site visit has an assigned Field Rep.
In the parent record, I need fields that count how many of the site visits are assigned to each Field Rep, up to 3 and ranked by number of site visits.
So the result needs to be something like:
[rep1]= rep with most site visits
[rep2]= rep with second most
[rep3]= rep with third most
How might I accomplish this?
------------------------------
Jeff Peterson
------------------------------
Each site visit has an assigned Field Rep.
In the parent record, I need fields that count how many of the site visits are assigned to each Field Rep, up to 3 and ranked by number of site visits.
So the result needs to be something like:
[rep1]= rep with most site visits
[rep2]= rep with second most
[rep3]= rep with third most
How might I accomplish this?
------------------------------
Jeff Peterson
------------------------------