Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi everyone,
Could someone assist me with a DAX formula?
Firstly, I have the following data model:
I possess a Date table that enables me to define a date range using a slicer.
I maintain a list of articles, named "Articles," with "cod_art" as the primary key.
I also have a list of sales, named "Sales," which is linked to the "Articles" table via the "cod_art" field, along with two other fields indicating the sales quantity and date.
Additionally, there's a final table named "Article_price_list," detailing price variations for each article. This table is connected to the "Articles" table through the "cod_art" field, providing the article's price and the effective date of that price.
My objective is to create the following matrix:
I can set a date range, and within this range, the matrix will display the effective date for each article. However, what I'm struggling with is creating a DAX formula to calculate the sum of quantities sold for each effective date (i have to calculate the actual number of the sum, not the whole text in the above image).
I would greatly appreciate it if someone could offer their assistance with this matter.
Thank you very much!
Hi @BI_user2023
You can use sumx function.
e.g
Measure=SUMX(Article,[price]*[quantity]))
If the function cannot meet your requirement, can you provide some sample data or file so that can provide more useful suggestion for you.
Best Regards!
Yolo Zhu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
23 | |
7 | |
7 | |
6 | |
6 |
User | Count |
---|---|
27 | |
12 | |
10 | |
9 | |
6 |