Hi,
I am again doing some learning and struggling to understand few things. I want to understand how to write formulas in a PowerBI data view by adding new columns. Please see the below image and attached PowerBI file.
Questions 123.pbix (2.0 MB)
I created this table using formula:
Calculated Table =
SUMMARIZECOLUMNS(
‘Product-Lookup’[product_brand],
“Transactions”, [Sales])
I added calculated column Transactions 2 by creating a relationship between the fact table transactions and dimension table using formula: CALCULATE([Sales])
- Is there a better way of doing this ? If I do not add Calculate, the result I get is the grand total for the dataset.
I want to add Running Total to a data table. I tried doing it by this formula but it added grand total.
- How do I make this work ?
Running Total DataTable =
CALCULATE(
[Sales],
FILTER(ALLSELECTED(‘Calculated Table’), ‘Calculated Table’[product_brand]<=MAX(‘Calculated Table’[product_brand]))
)
If i use this formula on a visualization it works.
Running Total DataTable =
CALCULATE(
[Sales],
FILTER(ALLSELECTED(‘Calculated Table’), ‘Calculated Table’[product_brand]<=MAX(‘Calculated Table’[product_brand]))
)
Thank you!!
Hi @Roboboboberts, did the response provided by @IlgarZarbaliyev help you solve your query? If not, how far did you get and what kind of help you need further? If yes, kindly mark as solution the answer that solved your query. Thanks!
Hello @Roboboboberts,
I see no reason for you to use the calculated table.
You can just use the measures to achieve what you are looking for.
here’s the PBIX file. Hope this answers your questions. If so, please mark this as a solution.
Good luck
Questions 123.pbix (2.3 MB)
Hi @Roboboboberts, we’ve noticed that no response has been received from you since the 18th of March. We just want to check if you still need further help with this post? In case there won’t be any activity on it in the next few days, we’ll be tagging this post as Solved.
Hi @Roboboboberts, due to inactivity, a response on this post has been tagged as “Solution”. If you have a follow question or concern related to this topic, please remove the Solution tag first by clicking the three dots beside Reply and then untick the check box.
We’ve recently launched the Enterprise DNA Forum User Experience Survey, please feel free to answer it and give your insights on how we can further improve the Support forum. Thanks!
With a little delay, but thank you I just used the feedback from you again. Thanks a lot!
1 Like
I’ve been off myslef for some time . U welcome
1 Like