Run aggregation pipeline and sort results by a set of match priorities

Thank you @Pavel_Duchovny and @steevej for your replies.

I wasn’t familiar with MongoDB Atlas before, so @Pavel_Duchovny thank you for pointing me in the right direction!

@steevej, thank you for you elegant solution - it works brilliantly and have extended it for more complex sorting priorities. It will serve as an excellent interim solution until we are in a position to use MongoDB Atlas.

2 Likes