weizer
weizer

Reputation: 1127

How to remove the time and minus one day in Power Query?

enter image description here

Hi everyone,

I have a column showing date and time. I want to remove the time behind the date and then minus one day off from the date. For example, if the date and time is 8/18/2019 6:51:00PM, the final output will be 8/17/2019. Or if the date and time is 10/27/2019 6:23:00PM, then the out put will be 10/26/2019. How to achieve this in Power Query? The output column should be a new column instead of replacing the old column. Any help will be greatly appreciated!

Upvotes: 0

Views: 6699

Answers (1)

user10471965
user10471965

Reputation:

In Power Query, go to the ribbon on top and press 'Add Column', on the left side you will now see 'Custom Column'

Add new column

Here you can type a formula. I've made the following:

Power Query

Upvotes: 2

Related Questions