What is the simplest way to express in T-SQL that only 1 and exactly 1 of a number of boolean conditions is true (needs to be usable in a CHECK constraint)?

`XOR` works for 2 conditons, eg `A XOR B` will insure that exactly 1 is set but it does not work for 3 conditions:

![](https://i.imgur.com/a8tpn8L.png)

One solution would be to get some kind of collection out of them, filter on the conditions being true, perform and aggregate/sum and check that the result is equal to 1.