Microsoft is giving away 50,000 FREE Microsoft Certification exam vouchers!
Enter the sweepstakes now!Prepping for a Fabric certification exam? Join us for a live prep session with exam experts to learn how to pass the exam. Register now.
I have a calculated field that averages scores. I want to create columns that return the score for january/february so I can have the Jan score, feb score and YTD score all within the same table visual.
I tried to do a simple IF(month([date])=1,[score]) = Jan score. But it wont let me return my score column in this calculation.
Any other thoughts or easier ways of going about this?
Solved! Go to Solution.
Hi, @trevordunham
I'm happy to answer your questions. Based on your description, I used the following sample data:
We now need the score columns corresponding to January and February. We can use the SUMMARIZE function to group the dates.
Use the above function to create two new tables, containing the score columns for January and February respectively.
Table DAX formula:
Table = CALCULATETABLE(SUMMARIZE('Sheet2','Sheet2'[name],'Sheet2'[score],'Sheet2'[date]),MONTH('Sheet2'[date])=1)
The results are as follows:
Table2 DAX formula:
Table2 = CALCULATETABLE(SUMMARIZE('Sheet2','Sheet2'[name],'Sheet2'[score],'Sheet2'[date]),MONTH('Sheet2'[date])=2)
The results are as follows:
Create relationships into two new tables:
Use January and February score columns in table visual:
To learn how to use the SUMMARIZE function, you can click on the link: https://dax.guide/summarize/
I have provided the sample PBIX file used this time below. If the above suggestions are helpful to you, that would be great.
How to Get Your Question Answered Quickly
If it does not help, please provide more details with your desired output and pbix file without privacy information (or some sample data) .
Best Regards
Jianpeng Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, @trevordunham
I'm happy to answer your questions. Based on your description, I used the following sample data:
We now need the score columns corresponding to January and February. We can use the SUMMARIZE function to group the dates.
Use the above function to create two new tables, containing the score columns for January and February respectively.
Table DAX formula:
Table = CALCULATETABLE(SUMMARIZE('Sheet2','Sheet2'[name],'Sheet2'[score],'Sheet2'[date]),MONTH('Sheet2'[date])=1)
The results are as follows:
Table2 DAX formula:
Table2 = CALCULATETABLE(SUMMARIZE('Sheet2','Sheet2'[name],'Sheet2'[score],'Sheet2'[date]),MONTH('Sheet2'[date])=2)
The results are as follows:
Create relationships into two new tables:
Use January and February score columns in table visual:
To learn how to use the SUMMARIZE function, you can click on the link: https://dax.guide/summarize/
I have provided the sample PBIX file used this time below. If the above suggestions are helpful to you, that would be great.
How to Get Your Question Answered Quickly
If it does not help, please provide more details with your desired output and pbix file without privacy information (or some sample data) .
Best Regards
Jianpeng Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Check out the April 2025 Power BI update to learn about new features.
Explore and share Fabric Notebooks to boost Power BI insights in the new community notebooks gallery.
User | Count |
---|---|
72 | |
71 | |
68 | |
42 | |
42 |
User | Count |
---|---|
46 | |
40 | |
28 | |
27 | |
26 |