Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
jochendecraene
Helper IV
Helper IV

How to keep the age correct over the years

Hi all

 

I got a table with some cliënts and their age, adress, ...

ex; Jones Johnson, age 56, ....

 

Can I create a measure so that I can keep this age of 56 correct over the years?

 

thx

1 ACCEPTED SOLUTION

Hi @jochendecraene ,

 

You can use the following column:

 

actualage  = datediff(DATE(2021,1,1), today(), year)+Table[age]

 

Or measure:

actualage  = datediff(DATE(2021,1,1), today(), year)+MAX(Table[age])

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Best Regards,

Dedmon Dai

 

 

 

 

 

View solution in original post

3 REPLIES 3
amitchandak
Super User
Super User

@jochendecraene , If you have a Date of birth, even a column can do that

 

new column

age  = datediff([dob], today(), year)

 

new measure

age  = datediff(min(Table[dob]), today(), year)

The problem is that the dataset contains no DOB, they only give me the age. They don't register DOB ...

Hi @jochendecraene ,

 

You can use the following column:

 

actualage  = datediff(DATE(2021,1,1), today(), year)+Table[age]

 

Or measure:

actualage  = datediff(DATE(2021,1,1), today(), year)+MAX(Table[age])

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Best Regards,

Dedmon Dai

 

 

 

 

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.