SUMX DAX Function in Power BI

The SUMX DAX function returns the sum of an expression evaluated for each row in a table.

DAX Syntax SUMX(table, expression)

The function has the following parameters:
table: The table containing the rows for which the expression will be evaluated. The table can be a table-expression.
expression: The expression to be evaluated for each row of the table.

Example: Create a measure.

DAX

Sumx value = SUMX(FILTER(Sheet1, [10th Marks]>400), [10th Marks])

This DAX expression calculates the sum of the "10th Marks" column in "Sheet1", but only for rows where the "10th Marks" are greater than 400.

The output of the above measure can be shown in the card visual as shown in the image below.

SUMX dax function in Power BI