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
Anonymous
Not applicable

Calculation with the date format

Hello,

 

I have a column with they format DD/MM/YYYY hh:mi:ss and other column with a value at that date&time. so for example:

 

Date                                   Value

30/03/2012 09:00              100

30/03/2012 10:00              200

31/03/2012 09:00              100

 

I would like to see this in my dashboards:

30/03/2012               300

31/03/2012               100

 

I changed in modelling the format to dd/mm/yyyy but the data are presented like this:

30/03/2012               100

30/03/2012               200

31/03/2012               100

 

What can I do?

1 ACCEPTED SOLUTION

@Anonymous

 

Try to create a calculated column with following formula in Reading table. And change the data type to Date.

 

Column = 
DATE ( YEAR ( Reading[Interval Date] ), MONTH ( Reading[Interval Date] ), DAY ( Reading[Interval Date] ) )

In the table visual, use above column instead of Interval Date.

Calculation with the date format_1.jpg

 

Best Regards,
Herbert

View solution in original post

8 REPLIES 8
Anonymous
Not applicable

Unfortunately this is not what happens to me.

I have the column in format 31/03/2012 09:00. I just went to modelling and I changed format to 31/03/2012, but this is not the original format.

 

Sin título.jpg

Sin título2.jpg

@Anonymous

 

Please try to change Data type from Date/Time to Date.

 

Best Regards,
Herbert

Anonymous
Not applicable

it doesnt work, ithappens exactly the same thing.

@Anonymous

 

Could you please provide your PBIX file to me? You can share it through online file service like OneDrive.

 

Best Regards,
Herbert

Anonymous
Not applicable

Check if you have access to this folder. Thank you!

https://drive.google.com/open?id=0B3W6nmMyLpR9WkxrbGhoMUtWUEE

 

@Anonymous

 

Try to create a calculated column with following formula in Reading table. And change the data type to Date.

 

Column = 
DATE ( YEAR ( Reading[Interval Date] ), MONTH ( Reading[Interval Date] ), DAY ( Reading[Interval Date] ) )

In the table visual, use above column instead of Interval Date.

Calculation with the date format_1.jpg

 

Best Regards,
Herbert

Anonymous
Not applicable

Thank you! It worked!

v-haibl-msft
Employee
Employee

@Anonymous

 

When you create the Table visual in the canvas, the values can be summarized as below.

 

Calculation with the date format_1.jpg

 

Best Regards,
Herbert

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.