Background
Some times we need trigger a task at every month end, the last day of every month, i.e. cache business data.
Run a NetSuite scheduled script at every month end, can't be achieved by setup Script Deployment > Schedule:
|
When you hit 'Monthly Event', the option can't locate to the LAST day of every month.
Day of every month(s) |
of every month(s) |
Steps:
1. Setup Script Deployment > Schedule to run for Every Day, I.e. 6PM (as above table)
2. Driven by saved search schedule can use this criteria to return result ONLY on last day of every month:
Formula (Numeric)
CASE TO_CHAR({today},'MM/DD/YYYY') WHEN TO_CHAR(LAST_DAY({today}),'MM/DD/YYYY') THEN 1 ELSE 0 END
Make this criteria equal to 1, will achieved results at the end of every month.