# How to aggregate values as a product (multiplication) in MDX

MDX has some built-in aggregation functions - Sum, Count, Min and Max. There is also an ubiquitous Aggregate function, which will aggregate values according to the current measure aggregation function, which also adds Distinct Count and all of the semiadditive measures. But what if we need to compute not the Sum, but rather the Product (Multiplication) of values. The example that we will look here is somewhat artificial, but it is done on Adventure Works cube, so it can be repeated. Let's assume that we need to multiply the weights from the leaves of the Organization hierarchy. We can easily extract these weights with following query:

Tags: mdx