Essentially, I have:
- a
bandscollection - each band may or may not have an array of
players - each player has an array of
roles(string)
E.g.:
// a band
{
_id: 1,
players: [
{
name: "George",
roles: [ "GUITAR" ]
},
{
name: "John",
roles: [ "SINGER", "GUITAR" ]
},
{
name: "Paul",
roles: [ "SINGER", "BASS GUITAR" ]
},
{
name: "Ringo",
roles: [ "DRUMS" ]
},
]
}
I need to determine if there is any band which contains more than one member having the SINGER role.