Ok. Based on the assumptions below taken from your comments:
Try this:
=IF($N1="","",IF(ISERROR(SEARCH("CS",$N1)),"IG","CS"))
How this formula works:
- In col N is blank, then return blank.
- If col N is not blank, check if the search for "CS" in col N returns
an error.
- If an error is returned, that means col N does not contain "CS", and
therefore, returns "IG".
- If the search does not return an error, it means that "CS" was found
and that is what should be returned.
If you need any more clarification, just let me know.
EDIT: AS AN ASIDE
In your comments, you said that in column N, you have this formula:
=IFERROR(VLOOKUP($F20,Data!$A:$J,9,FALSE), 0)
I can see a few issues with this:
- As you are returning column 9, that is column I, so your range could be Data!$A:$I (I am not sure but, as it is a smaller range, it may calculate quicker).
- If a value is not found, it will return zero, not blank, which is what my formula above is checking for.
- You should consider using an INDEX/MATCH formula instead, as it is much quicker and more versatile.
Please see my suggested formula below:
=IF(INDEX(Data!$I:$I,MATCH($F20,Data!$A:$A,0))="","",INDEX(Data!$I:$I,MATCH($F20,Data!$A:$A,0)))