The solution I used was the following:
2n9 credit from google forums. Here's a link
=arrayformula(sumif(B3:B8&C3:C8,F3:F8&"A",A3:A8))
There were some other very good answers there, using queries from Jean-Pierre Verhulst:
=query(A2:C8, "select B, sum(A) group by B pivot C")
=query(query(A2:C8, "select B, sum(A) group by B pivot C"), "select Col2, Col3")
=ArrayFormula(query(query(A2:C8, "select B, sum(A) group by B pivot C"), "select Col2, Col3 offset 1",0)+0)
Each of these solutions solves the problem, but in a different way. They have different attributes, such as deleting headings or selecting only a specific column. For more information, use the google forum link.
Hope this helps someone.
Catu source share