Using OR logic on an array as argument in Sumproduct

后端 未结 7 559
南旧
南旧 2021-01-12 04:47

I\'m having a fairly large dataset where I need to combine multiple entries into a single value. My dataset contains data on the combination of two datasets, each using thei

7条回答
  •  独厮守ぢ
    2021-01-12 05:07

    You could make a small change to your current formula; change the ; to * (-- are also unneeded in that particular case):

    =SUMPRODUCT(('Raw data'!C:C=Landgebruik!A2)*('Raw data'!O:O={20;21;22;23;40})*'Raw data'!S:S)
    

    And that should work.


    When you feed separate parameters to SUMPRODUCT, each parameter has to be of the same size. But when you multiply them like this, it forces evaluation and the arrays expand.

    For example, if you take two arrays, 5x1 and 1x5, you get a 5x5 resulting array:

提交回复
热议问题