I am writing a formula to read a cell that contains city names, and I want to output a general region/area.
In order to do this, I have written an "IF" formula that uses the "CONTAINS" function so it doesn't have to be an exact match. But I also want the output to be dynamic... so if the cell contains say Paris and Hong Kong, the formula would output TWO regions rather than the first condition that is met.
Today it looks like this:
=IF((ISBLANK([Site Impact]1)), "None", IF(CONTAINS("Sydney", [Site Impact]1), "Australia", IF(CONTAINS("Hong Kong", [Site Impact]1), "East Asia", IF(CONTAINS("Shanghai", [Site Impact]1), "East Asia", IF(CONTAINS("Tokyo", [Site Impact]1), "East Asia", IF(CONTAINS("Hong Kong", [Site Impact]1), "East Asia", IF(CONTAINS("Berlin", [Site Impact]1), "Europe, Middle East and Africa", IF(CONTAINS("Dublin", [Site Impact]1), "Europe, Middle East and Africa", IF(CONTAINS("Dundalk", [Site Impact]1), "Europe, Middle East and Africa", IF(CONTAINS("London", [Site Impact]1), "Europe, Middle East and Africa", IF(CONTAINS("Luxembourg", [Site Impact]1), "Europe, Middle East and Africa", IF(CONTAINS("Moscow", [Site Impact]1), "Europe, Middle East and Africa", IF(CONTAINS("Paris", [Site Impact]1), "Europe, Middle East and Africa", IF(CONTAINS("Tel Aviv", [Site Impact]1), "Europe, Middle East and Africa", IF(CONTAINS("Guatemala", [Site Impact]1), "Latin America", IF(CONTAINS("Sao Paolo", [Site Impact]1), "Latin America", IF(CONTAINS("Chandler", [Site Impact]1), "North America", IF(CONTAINS("Chicago", [Site Impact]1), "North America", IF(CONTAINS("New York", [Site Impact]1), "North America", IF(CONTAINS("San Francisco", [Site Impact]1), "North America", IF(CONTAINS("San Jose", [Site Impact]1), "North America", IF(CONTAINS("Vancouver", [Site Impact]1), "North America", IF(CONTAINS("Bengaluru", [Site Impact]1), "Southeast Asia", IF(CONTAINS("Chennai", [Site Impact]1), "Southeast Asia")))))))))))))))))))))
It outputs the first condition met only. I'm interested in checking against ALL conditions. Do I have to write additional "IF" conditions that combine every permutation of combinations to achieve this or is there an easier way? Trying to save myself eye strain.