Question Regarding Date

Case :-1:

I have data in Google Sheets as Due Date, and I want to execute the next node ( send email or SMS ) 4 days before the due date, So what should I use please help me i tried lot but not able to find

@chandan988 sounds like you will need to use the Wait node.

Here is an example:

Things to keep in mind:

  • I created a DateTime object in the Set node (“Create a mock date (7 days in future)”). The value you get from google sheets might currently be a string, so would first need to be converted to a DateTime object. You could use the “date & time” node to do this OR a javascript method like .toDate() . If you go the JavaScript route, the wait node’s expression would look something like {{ $json.propertyName.toDate().minus(4,"days") }} (so we first convert to a date object, then continue with the .minus transform)
  • In the Wait node, you’ll have to change propertyName to the name of the key from your Google Sheets step
  • Since the Wait node will do a “long” wait (more than 60 seconds), you won’t see it in the UI. Instead you have to ensure that manual executions are being saved, and then you can see the status of that execution. You should get some notifications about this in the UI when this occurs.

Hope that helps!

Hi @chandan988 ,

From what you describe, the workflow must run some kind of reminder. If so, a simple approach is the following workflow:



  • Run the workflow automatically once a day with the Schedule Trigger node.

  • Then define the variable “date” in the Set node, adding the 4 days margin until the due date.

  • Format the date field to match the format of the due_date field in the Google Sheets sheet (this step is optional, it will depend on how the fields are formatted).

  • We list the spreadsheet data, filtering the rows that only match their “due_date” column by the date we have set in the Set node and formatted in the previous node.

From here, you can continue the workflow with the steps you want.



Let me clear
Due date is suppose 25 Feb 2023, Then reminder should go 3 days before due date

this is my google sheet, Due Date is 26 Feb 2023, But i want to run this 3 days before ie on 23 Feb only to send email & sms

@chandan988 have you tried adapting @martinhache or my suggestion? Looking at your Google sheet, either of our solutions sound like they should get you what you’re looking for.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.