Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Connect 2026! Turn data into bold moves, April 13 -15: Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Date in Integer YYYYMM format

Hi,

I have a situation;where my input column is an integer that holds Year and Month (YYYYMM). Now I need to now find the previous month for the incoming integer. The output column is also an integer.

For ex: 

input_col (int)                  output_col (int)

201811                            201810

201901                            201812

201906                            201905

May I know how can do the same in tmap.

Labels (3)
1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

TalendDate.addDate(row1.input_col, "yyyyMM", -1, "MM")

you'll have to cast input_col to String to use this function

View solution in original post

2 Replies
Anonymous
Not applicable
Author

TalendDate.addDate(row1.input_col, "yyyyMM", -1, "MM")

you'll have to cast input_col to String to use this function

Anonymous
Not applicable
Author


@evansdar wrote:
TalendDate.addDate(row1.input_col, "yyyyMM", -1, "MM")

you'll have to cast input_col to String to use this function


Thank you very much. Works like a charm...!!!