Skip to main content
Solved

How to keep adding months to today's date?

  • September 12, 2019
  • 5 replies
  • 41 views

dataninja
Forum|alt.badge.img

Hi, how do I keep adding records (In red) until I hit 2025 - 12 - 12?

Thanks in advance!

Best answer by daveatsafe

Hi @trungn1993,

You can use a DateTimeCalculator transformer to calculate the number of days between today and 2025-12-12, then another one to calculate the date for each of those days:

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

5 replies

daveatsafe
Safer
Forum|alt.badge.img+19
  • Safer
  • 1637 replies
  • Best Answer
  • September 12, 2019

Hi @trungn1993,

You can use a DateTimeCalculator transformer to calculate the number of days between today and 2025-12-12, then another one to calculate the date for each of those days:


dataninja
Forum|alt.badge.img
  • Author
  • 44 replies
  • September 12, 2019

I figured it out.

 

 

First, I used a cloner:

 

And then used DateTimeCalculator for both Next_Month & Today_Date

 

Final Output:


dataninja
Forum|alt.badge.img
  • Author
  • 44 replies
  • September 12, 2019

Hi @trungn1993,

You can use a DateTimeCalculator transformer to calculate the number of days between today and 2025-12-12, then another one to calculate the date for each of those days:

I just posted my solution too :) Thanks @daveatsafe anyways


paalped
Contributor
Forum|alt.badge.img+5
  • Contributor
  • 130 replies
  • September 12, 2019

I'm not gonna ask why, and rather just give one solution. But I do advice to calculate these values on the fly, and not create a lot of dead lookup data. Its a big performance killer.

 

 

Here is a Python Creator example:pyc.txt

 

 


dataninja
Forum|alt.badge.img
  • Author
  • 44 replies
  • September 12, 2019

I'm not gonna ask why, and rather just give one solution. But I do advice to calculate these values on the fly, and not create a lot of dead lookup data. Its a big performance killer.

 

 

Here is a Python Creator example:pyc.txt

 

 

Thanks, nothing beats Python when it comes to performance!