I'm looking for a generalisation of Yao's millionaire problem: $N$ parties want to know whether they are the richest one. If they are not, then they just know they are not the richest party - but do not know the identity of the richest one.
Ideally, in case of equality, all richest members would know they are the richest, but would not know if others are as rich.
Does such a protocol already exist?
Edit: obviously when there are only two users, then everyone knows who is the richest. I guess a formalization would be that not-richest people cannot guess who, amongst remaining users, is richest, with probability better than random.
There exist such constructions, for instance assume a FHE scheme which takes the encrypted values as input, and output for each party $p_i$ their result, encrypted with $p_i$'s key. While this should work (it may need some work for the encryption of the inputs but anyway), it is also extremely tedious.