Forum Discussion
How to Show Ratio?
hi,
i want to write dax for ratio.
for example-Column A=27 and and column B=18, 27/18 , so i want to show the value 3:2
Thanks in Advance.
Hi mithiladas02 ,
Create a column with below code:-
Column = VAR _value = GCD ( [A], [B] ) RETURN DIVIDE ( [A], _value ) & ":" & DIVIDE ( [B], _value )output:-
Thanks,
Samarth
2 Replies
- Samarth_18Community Champion
Hi mithiladas02 ,
Create a column with below code:-
Column = VAR _value = GCD ( [A], [B] ) RETURN DIVIDE ( [A], _value ) & ":" & DIVIDE ( [B], _value )output:-
Thanks,
Samarth
- parry2kSuper User
mithiladas02 not sure but add a new column with the following expression:
Ratio Column = DIVIDE ( Table[Col A]. Table[Col B] )✨ Follow us on LinkedIn and to our YouTube channel
Learn about conditional formatting at Microsoft Reactor
My latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.