PRODUCTX

The PRODUCTX function returns the product of the values taken by an expression that is evaluated for all rows in a table.

Syntax

PRODUCTX(
    table,
    expression
)

Parameters
  • table: Table containing the rows for which the expression will be evaluated. It can be the name of an existing table or an expression that returns a table.
  • expression: Expression to evaluate for each row of the table.
Returned value

The PRODUCTX function returns a real number.

Additional Information

The function only considers numbers, ignoring Blanks, logical values and text strings.

Examples

If we start from the following data table:

PRODUCTX function. Example of use

...we can calculate the product of the values resulting from evaluating the expression Qty * Pct for each row with the following measure:

Result = PRODUCTX(Data, Data[Qty] * Data[Pct])

Taking it to a card-type display we obtain the following result:

PRODUCTX function. Example of use

...value resulting from multiplying the partial results in each row, results that we can show in a calculated column if we want to confirm the final result:

PRODUCTX function. Example of use

Indeed, the product of the values 2.4, 2.4, 3.2, 4.5 and 3.2 returns the value 265.4208.

Related functions
Category
Mathematical and trigonometric
Submitted by admin on Sat, 01/05/2019 - 14:37