Representation Between Excel and Power Query

Mruizch21

New Member
Joined
Jan 23, 2024
Messages
2
Office Version
  1. 365
Platform
  1. Windows
I'm experiencing an issue when working with a specific date and time value in Excel and Power Query. In Excel, when I read the data "2/25/1900 6:00:00 AM," the decimal representation is 56.25, which is the expected result. However, when I upload the same data to Power Query, the decimal representation becomes 57.25.

I've ensured that the regional and date format settings are consistent between Excel and Power Query. Could someone shed light on why this discrepancy might be occurring and how I can align the decimal representations between the two?
 

Excel Facts

What is the last column in Excel?
Excel columns run from A to Z, AA to AZ, AAA to XFD. The last column is XFD.
Dates prior to 1st March 1900 in Excel will be one day off compared to PQ since Excel treats 1900 as leap year (due to historical compatibility issues) whereas PQ recognises that it was not a leap year.
 
Upvote 1
Thank you for explaining the discrepancy related to dates prior to March 1, 1900. Regarding the decimal data processing, I believe it's related to the same challenge. It appears that in the first stage of the upload, the data is being read in its date and time format. When I subsequently change it back to the decimal format, it adds '1' to the values, resulting in '57.25' instead of the original '56.25.'

Could you provide guidance on how to address this specific aspect of the challenge? I want to ensure that Power Query processes the data to '56.25' without introducing the additional '1.' considering the the excel that I am uploading the data point is in the decimal format 56.25. Is there a quick way to correct this?
 
Upvote 0
Check if the date is less than 1st March 1900. If it is, subtract 1 otherwise leave it alone.
 
Upvote 0

Forum statistics

Threads
1,223,880
Messages
6,175,155
Members
452,615
Latest member
bogeys2birdies

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top