I would like to make a SUMIFS formula where I can change the sum_range parametr dynamically on the grounds of this formula where I get the column: SUBSTITUTE(ADDRESS(1;MATCH("aaa";1:1;0);4);1;"")
In other words, I want to replace B:B in this formula =SUMIFS(B:B;A:A;"abc") with the formula above. But I am not able to combine those...
I found one solution here: https://stackoverflow.com/a/25814571/10452645 but I'm not quite satisfied with it. Is there another possibility to solve this task by combining SUMIFS and ADDRESS formula.

IFstatement to change what the sum range is, for example=sumifs(if(A1="Yes",A:A,B:B),etc.)this is just an example - Mark S.=SUMIFS(INDEX($1:$1048576;0;MATCH("aaa";$1:$1;0));A:A;"abc")- Scott Craner