Forum Discussion
Anonymous
7 years agoNot applicable
Create a new table from existing table with calculated measures
Hi Community, I need help with creating another table from the existing table with measures calculated with few conditions. I have a dataset with 10 Years for 2 companies and calculated measu...
Mariusz
Community Champion
7 years agoHi Anonymous
Please see the attached Table Expression.
YourNewTable =
ADDCOLUMNS(
GROUPBY(
FILTER(
ADDCOLUMNS(
YourTable,
"YearMonth",
VAR d = YourTable[Date]
RETURN YEAR( d ) * 100 + MONTH( d )
),
YourTable[Company] = "Company1"
&& [YearMonth] = 201901
),
YourTable[Company],
YourTable[Product],
[YearMonth]
),
"Value_cal", CALCULATE( SUM( YourTable[Value_cal] ) ) -- or replace Calculate with your Measure
) Regards,
Mariusz
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
7 years agoNot applicable
Thanks for the reply,
In my original dataset,
To calculate the final Value, I have Fixed the values with respect to year and each category and also used all except functions.
As per the above solution, it was giving wrong values
Any solution would be grateful
Thanks
Yamuna