Match / append based on multiple columns?

I am trying to compile product sales statistics. Every product has multiple attributes, one per column (think color, size, shape). I have a master sheet which contains the product attributes then monthly sales, one per column, for many months. I have a monthly sheet which contains enough of the product attributes to describe a product then one column for the current sales. For each row in the monthly sheet, I would like to match the available product attribute columns first. If there’s a match for every attribute then append the monthly sales figure to the matched row. If there is not then append the row to the master sheet as is.

I added a sample.
sample.ods (9.7 KB)

please attach a example.ods to your question.

Thanks for the rapid response, I’ve attached a sample.

See attached file
sample_with_pivottable.ods (20.8 KB)

My bad. I am so sorry and thanks for your efforts. I attached the sample with an output sheet. Hope it makes more sense.

sample.ods (10.5 KB)