The Excel SWITCH function is a neat alternative to nested IF functions or the IFS function.
It is a useful substitute and a real timesaver compared to complex nested IF formulas. It is more compact and easier to read.
Watch the Video
SWITCH Function Syntax
The SWITCH function compares a value (known as the expression) against a list of values, and returns the result for the first matching value. If a match is not found, a default result can be returned.
=SWITCH(expression, value1, result1, [default_or_value2, result2])
Expression: is the value to be tested against the list of values. This is typically a reference to a cell value such as A2.
Value1: is the first value (SWITCH can evaluate up to 126 values) to be compared against the expression.
Result1: is the action to perform if its corresponding value is a match to the expression.
Default: This optional default value provides SWITCH with an else argument. This is the result to return if there is no match found.
Let’s see some SWITCH function examples.
[Read more…] about Excel SWITCH Function – Nested IF Function Alternative