DAX Aggregation - ADDCOLUMNS function
Advertisements
Description
Adds calculated columns to the given table or table expression.
Syntax
ADDCOLUMNS (<table>, <name>, <expression>, [<name>, <expression>] …)
Parameters
Sr.No. | Parameter & Description |
---|---|
1 |
table Table or a DAX expression that returns a table. |
2 |
name The name given to the column, enclosed in double quotes. |
3 |
expression DAX expression that returns a scalar expression, evaluated for each row of table. |
Return Value
A table with all its original columns and the added ones.
Remarks
--
Example
= ADDCOLUMNS ( Products,"East_Sales", SUMX (RELATEDTABLE(East_Sales), IF([Product] = East_Sales[Product], East_Sales[Sales Amount],0) ) )
dax_functions_aggregation.htm
Advertisements