Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
I have a date column and i need to count the rows for a specific month. Such as an example, is there a way to create a measure that will count all the rows that contain "March"? I have tried a few things, but not making any progress.
Thanks in advance
Solved! Go to Solution.
Hi @StuartSmith ,
How about this:
TomsMeasure = CALCULATE ( COUNTROWS( Table ),
FILTER ( Date, Date[DateMonth] = "March" ) )
Hope that measure gives you some kind of start 🙂
[Edit] In case you do not have a date dimension this might work better:
TomsMeasure = CALCULATE ( COUNTROWS( Table ), FILTER ( Table, Table[Date].[Month] = "March" )
)
/Tom
https://www.tackytech.blog/
https://www.instagram.com/tackytechtom/
Did I answer your question❓➡️ Please, mark my post as a solution ✔️ |
Also happily accepting Kudos 🙂 |
Feel free to connect with me on LinkedIn! |
#proudtobeasuperuser |
Thanks, that worked!
Hi @StuartSmith ,
How about this:
TomsMeasure = CALCULATE ( COUNTROWS( Table ),
FILTER ( Date, Date[DateMonth] = "March" ) )
Hope that measure gives you some kind of start 🙂
[Edit] In case you do not have a date dimension this might work better:
TomsMeasure = CALCULATE ( COUNTROWS( Table ), FILTER ( Table, Table[Date].[Month] = "March" )
)
/Tom
https://www.tackytech.blog/
https://www.instagram.com/tackytechtom/
Did I answer your question❓➡️ Please, mark my post as a solution ✔️ |
Also happily accepting Kudos 🙂 |
Feel free to connect with me on LinkedIn! |
#proudtobeasuperuser |
Actually, your first suggestion worked...
Hi @StuartSmith ,
Oh, awesome! I did not know you had a date dimension 🙂
I'll update my previous answer so you can mark it as a solution!
/Tom
https://www.tackytech.blog/
https://www.instagram.com/tackytechtom/
Did I answer your question❓➡️ Please, mark my post as a solution ✔️ |
Also happily accepting Kudos 🙂 |
Feel free to connect with me on LinkedIn! |
#proudtobeasuperuser |
User | Count |
---|---|
103 | |
90 | |
78 | |
72 | |
68 |
User | Count |
---|---|
108 | |
96 | |
95 | |
74 | |
71 |