Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hello,
I have very simple measure contains SUM of numbers. The result of this measure is standard number e.g. 1 2,3,4,....59,..... etc.
It is possible to recreate this measure to showing ordinary numbers like 1st, 2nd....21th etc?
Thank you for your help
Solved! Go to Solution.
Based on your needs, I have created the following table.
Then you can use the following Dax to get the result you want:
Ordinal Numbers =
VAR _Last2Number = RIGHT( [Standard number], 2 )
VAR _LastNumber = RIGHT( [Standard number], 1 )
RETURN
[Standard number]&SWITCH( TRUE( ),
_Last2Number IN { "11", "12", "13" }, "th",
_LastNumber = "1", "st",
_LastNumber = "2", "nd",
_LastNumber = "3", "rd",
"th"
)
Result:
Best Regards,
Jayleny
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Based on your needs, I have created the following table.
Then you can use the following Dax to get the result you want:
Ordinal Numbers =
VAR _Last2Number = RIGHT( [Standard number], 2 )
VAR _LastNumber = RIGHT( [Standard number], 1 )
RETURN
[Standard number]&SWITCH( TRUE( ),
_Last2Number IN { "11", "12", "13" }, "th",
_LastNumber = "1", "st",
_LastNumber = "2", "nd",
_LastNumber = "3", "rd",
"th"
)
Result:
Best Regards,
Jayleny
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks a lot, it works perfect!
If you mean ordinal numbers then unfortunately there isnt an inbuilt function in DAX.However you can have a look at this article on possible ways on how to achieve it
https://gorilla.bi/power-bi/ordinal-numbers/
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 6 | |
| 6 | |
| 4 | |
| 4 | |
| 4 |
| User | Count |
|---|---|
| 24 | |
| 17 | |
| 10 | |
| 7 | |
| 6 |