Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Sunilkumar3
Contributor III
Contributor III

How to Replace the time

Hi Team,

Hope you are doing well. Team, I have a small issue Regarding the Date and Time. I have a date_time field in my data and I want to change the time. So, to do that. Please see the below Eg.

Eg. 

Date_Time

2023-04-11 17:00:00
2023-04-12 17:00:00
2023-04-13 17:00:00
2023-04-3 12:30:00  

 

Ans:

Date_Time

2023-04-11 16:00:00
2023-04-12 16:00:00
2023-04-13 16:00:00
2023-04-03 12:30:00  

 

Labels (3)
1 Reply
Or
MVP
MVP

You've given no indication what logic you want to use to change the time...

Generally speaking, you can just use simple mathematical operators to modify datetime fields, e.g.  Date_Time + (1/24) will add one hour.