Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
prabuj
Contributor III
Contributor III

How to subtract a date in a column with one day ?

Dear Team, @Xiaodi Shi @Shicong Hong @TRF

Could you please help out to solve this requirement ? I would like to subtract a day from a date column.

DATE -1

For ex:

INPUT

1992-04-26 15:03:22

REQUIRED OUTPUT:

1992-04-25 15:03:22

Thanks in advance.

Labels (2)
1 Solution

Accepted Solutions
dilip_n
Contributor II
Contributor II

Hi there,

you can use "add date" function in tmap.

In tMap use like this :- TalendDate.addDate(date_column,-1,"dd").

Here if you use "-1" as "days" and it will subtract date. do this and try it.

 

0695b00000fKFuSAAW.png0695b00000fKFvBAAW.png

View solution in original post

1 Reply
dilip_n
Contributor II
Contributor II

Hi there,

you can use "add date" function in tmap.

In tMap use like this :- TalendDate.addDate(date_column,-1,"dd").

Here if you use "-1" as "days" and it will subtract date. do this and try it.

 

0695b00000fKFuSAAW.png0695b00000fKFvBAAW.png