Forum Discussion
Chelena
8 years agoRegular Visitor
Birthday in human readable language
Good day I'm a nurse working with with paediatric data. I want the column to display age "2y; 1m; 4d" from age in days. My excel recipe for this is as follows, it works fine: =INT([@Age]/365.24...
- Anonymous8 years ago
Chelena,
Directly create a calculated column using DAX below.col = INT([Age]/365.2425)&"y; " & INT(([Age]-INT([Age]/365.2425)*365.2425)/30.44)&"m; " &INT([Age]-INT([Age]/365.2425)*365.2425-INT(([Age]-INT([Age]/365.2425)*365.2425)/30.44)*30.44)&"d"
Regards,
Lydia
Anonymous
8 years agoNot applicable
Chelena,
Directly create a calculated column using DAX below.
col = INT([Age]/365.2425)&"y; " & INT(([Age]-INT([Age]/365.2425)*365.2425)/30.44)&"m; " &INT([Age]-INT([Age]/365.2425)*365.2425-INT(([Age]-INT([Age]/365.2425)*365.2425)/30.44)*30.44)&"d"
Regards,
Lydia
Chelena
8 years agoRegular Visitor
Thank you Lydia @v-yuezhe-msft ! I must still get use to the BI interface. I was trying to do it by editing the query / Power Query because I'm more familiar with it. I didn't think of the modeling ribbon.
But if there is anybody out there that can solve this in (power) query, it will be appreciated.
Thank you for your time Lydia. I will use it a lot and in future and try and remember the modeling ribbon. :smileyvery-happy: