To sum numbers if cells contain text in another cell, you can use the SUMIFS function or the SUMIF function with a wildcard. In the example shown the formula in cell F5 is: =SUMIFS(data[Amount],data[Location],"*, "&E5&" *") Where data is an Excel Table in the range B5:C16. As the formula is copied down, it returns a sum for each state in column E. Note the formula is using a wildcard (*) and extra space in the criteria. See below for details and for a case-sensitive option.