Consider pivoting these data: On the data source tab, ctrl-click to select all columns to be pivoted, right-click, Pivot. With this done you can reference [Pivot Field Names] in your calculated field, applying string functions as desired to identify the values to sum.
[COMP hors challenge] =
SUM(IF CONTAINS([Pivot Field Names],"COMP")
AND NOT CONTAINS([Pivot Field Names],"CHALLENGE"))
THEN [Pivot Field Values]
Thanks Eric. That approach is interesting. But how would you account for the fact that the header titles in the source file might change as they get refreshed, the only stable variables being "COMP" and "CHALLENGE" ?
By the way, the workflow I am creating is in Maestro Beta 4.
I imagine that the changing headers in the source file was also an issue with the previous approach. When connecting to a source file with new headers it will be necessary to pivot the data again, after which the rest of the calculations and worksheet will work without additional modification. I don't know of an approach requiring less intervention. If presented with this issue I would first attempt to standardize the source file; solutions that accept a changing source file are likely to demand frequent maintenance. Good luck with your solution!