Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Hello
How can I sum a total value within some weeks, and display the "total" only on the defined weeks , and show blank on other weeks ?
I have tried > caculate ( sum (sales value), filter( Allselected(table), year_week>=202201 && year_week <=202204)) , but it showed the total on all weeks in the year.
below is what I would like to achive :
week; value
40: blank
...
51; blank
52; blank
1; 100
2; 100
3; 100
4; 100
5; blank
...; blank
thanks in advance
Hi @Anonymous ,
Any updates?
If any of the reply above could solve your issue, please kindly Accept it as the solution. More people will benefit from it. Or if you are still confused about it, please provide me with more details about your table and your problem or share me with your pbix file after removing sensitive data.
Best Regards,
Eyelyn Qin
Hi @erche3
You can create a Calculated Column and use IF ( AND ... BLANK() ) to solve this like below:
Outside of Parameters = IF ( AND ( 'Table'[Date] < DATE ( 2022 , 4 , 30 ) , 'Table'[Date] < DATE ( 2022 , 12 , 15 ) ) , 'Table'[Amount] , BLANK() )
Ensure to modify the Table and Column name to suit your data and also adjust the dates as you require using the YYYY , MM , DD approach.
All the best 🙂
Theo
If I have posted a response that resolves your question, please accept it as a solution to formally close the post.
Also, if you are as passionate about Power BI, DAX and data as I am, please feel free to reach out if you have any questions, queries, or if you simply want to connect and talk to another data geek!
Want to connect?www.linkedin.com/in/theoconias
Hi @Anonymous ,
Please remove the ALLSELECTED() :
Measure = CALCULATE(SUM('Table'[Value]),FILTER('Table',[year_week]>=202201 && [year_week]<=202204))
Best Regards,
Eyelyn Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous
You can create a Calculated Column and use IF ( AND ... BLANK() ) to solve this like below:
Outside of Parameters = IF ( AND ( 'Table'[Date] < DATE ( 2022 , 4 , 30 ) , 'Table'[Date] < DATE ( 2022 , 12 , 15 ) ) , 'Table'[Amount] , BLANK() )
Ensure to modify the Table and Column name to suit your data and also adjust the dates as you require using the YYYY , MM , DD approach.
All the best 🙂
Theo
If I have posted a response that resolves your question, please accept it as a solution to formally close the post.
Also, if you are as passionate about Power BI, DAX and data as I am, please feel free to reach out if you have any questions, queries, or if you simply want to connect and talk to another data geek!
Want to connect?www.linkedin.com/in/theoconias