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

powerBI Desktop - data type changed in 'Data' tab doesn't reflect in the charts in 'Report' tab

Hi team,

 

  1. I have loaded the data from MongoDB to powerBI Desktop. In the data loaded, there's a column called '_time' which actually is a timestamp. The values are like this "3/29/2022 2:53:36 PM".

  2. Then I switch to 'Data' tab, and a)changed the data type for '_time' column from 'Date/time' to 'Date'. for example, the value is changed from "3/29/2022 2:53:36 PM" to "3/29/2022". b) changed the Date format to 'm/d/yyyy'

Here is the screenshot before and after changed.

a) before change

 

cheriemilk_5-1652837278124.png

 

 

b) after change

 

 

cheriemilk_6-1652837310437.png

 

 

  1. Then I go to report tab to create a line chart by selecting '_time' as axis and 'count of userID' as Y axis. The expected chart I want is to get the count of userID by daily. But actually, powerBI doesn't return the expected result to me. It looks like that powerBI still calculate the count of UID by timestamp because almost all value is 1 for a time.

Actual Chart: 

cheriemilk_7-1652837340671.png

 

 

 

Expected Chart: 

 

 

cheriemilk_8-1652837371766.png

 

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous , Changing Data type in DAX will not remove timestamp. Do that in power query (That will remove timestamp)

 

Or create a new column

Date only = datevalue([Datetime])

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@Anonymous , Changing Data type in DAX will not remove timestamp. Do that in power query (That will remove timestamp)

 

Or create a new column

Date only = datevalue([Datetime])

Anonymous
Not applicable

Thanks for the solution

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.