Skip to main content
Announcements
Introducing a new Enhanced File Management feature in Qlik Cloud! GET THE DETAILS!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Month number problem

I have cases with various starting dates and thus also various payment and closing dates. I have managed to concatenate the different tables into one and the 3 dates into one, but I now need the following in the load script:

All starting dates should be month 0 (no problem)

Payment dates should then be month 1, 2, 3, 4 etc no matter if the payment month is April, May, June, July etc

Closing date should be after the same principle as Payment dates, i.e. starting date minus closing date

E.g.

Starting date March 2011=0, Payment date, March 2011=1, April 2011=2, May 2011=3, June 2011=4. Closing date: July 2011=5

Starting date April 2011=0, Payment date: April 2011=1, May, 2011=2, June 2011=3, Closing date: June 2011=3

How can I do this ?

3 Replies
prieper
Master II
Master II

Think that the ADDMONTHS()-function should be able to help - have you had a look into it?

HTH
Peter

Not applicable
Author

Thanks for taking your time to look into this.

Having read through the description of AddMonths, I don't think I can use it for this purpose but thanks anyway.

prieper
Master II
Master II

Can you then please re-describe the rule for closing-date?

Peter