I have a tableA
|Column1|Column2|Column3|
|NO |NO |YES |
|YES |YES |NO |
|NO |NO |NO |
My requirement is to count the number of Yes or No per row and display the greatest (or equal to) of them. My sample output should be like:
|Column1|Column2|Column3|Answer
|NO |NO |YES |No
|YES |YES |NO |Yes
|NO |NO |NO |No
I know i can use a where clause if my requirement was to count them column wise, but how do I get this to be done row wise?
CASE WHENclause