Does anyone know if Workflow Actions with Trigger ...
# suiteflow
j
Does anyone know if Workflow Actions with Trigger On = Scheduled and “Time of Day” selected with a Start Time set within a Workflow in a Sandbox accounts should work? I have a workflow setup in Sandbox and I can execute the start of it on demand but I have an Action in one of the States that is supposed to execute at a certain time each day as long as the Condition is met but it never seems to run. I am thinking it’s due to Sandbox not automatically running all background processes that would be able to trigger this but I can’t get confirmation from NetSuite Support that this is the case. Does anyone else know if it’s not working due to it being Sandbox? I have changed the Trigger On to something else and been able to to trigger the action manually as well as set the schedule to “Delay” option with a number for days to delay and both of these worked so I’m sure it’s not the Condition on the WF Action that is causing it.
j
FWIW there was something similar about scheduled scripts in 2023.1 release notes, so I'm guessing you're correct, but it doesn't say anything specic about workflows
message has been deleted
m
When using the Scheduled trigger in an Action or Transition I have ALWAYS had to set the Delay field
It never works without it
I have read through the documentation many times and the documentation seems to say "if you would like to set a delay you can", NOT "you MUST set a delay"...but my experience has shown if the delay is not set a Scheduled action or transition will not happen
However, you can set a scheduled workflow to run without a delay, but for some reason the aciton/transition does not act the same
j
Thank you both. @James Morris That’s the same thing I’ve noticed within SuiteAnswers as well. @MGBC Even in Production you’ve never had it work even in production w/out the Delay field set? With the Delay field set and the Start Time will the action run at that Start Time on the day where your delay would put you? IE - Start Time = 7am, Delay = 1 day then it runs 1 day after entering the State at 7am? I know with just using the Delay option it will run about 24hrs after entering the state with a delay of 1 day.
m
@justinb yes even in production I’ve never gotten it to work But you are correct it first evaluates your delay based on when the record enters the state. Then once the delay is satisfied it will trigger the action Record enters state at 5pm on day 1 Day 2 at 5pm the delay is satisfied Day 3 at 7am the action fires (considering your example of 7am) You could put a delay of 1hr then it wouldn’t take so long to trigger
j
@MGBC I just looked at my workflow to make the change and when selecting Time of Day the Delay field is disabled so I can’t have both the Start Time and Delay set. Which basically means I don’t really have control of what time the Action executes.
m
Oh man. That’s a bummer. Honestly I’ve never tried the Time of Day setting I’ve only used scheduled transitions/actions with a delay But after reading the documentation it could be the scheduled scripts in sandbox issue that @James Morris mentioned You could do a test in Prod with just some random custom record to see if it works Also the documentation says it evaluates the time of day AND additional criteria so maybe double check your record meets your condition
Also here is the wording on the scheduled trigger A scheduled action is considered for execution when a record in a workflow instance stays in a state with a scheduled action. Every 30 minutes, the scheduler analyzes the schedule properties for such actions. If an action meets the schedule properties and any additional conditions on the action, the action executes on the workflow instance and record. For more information, see Scheduling an Action and Action Conditions.
j
thanks for that 2nd section…. I hadn’t found that one in SuiteAnswers. What I’m thinking (and going to test now) is that I never had a “recurrence” set so from the wording in those help articles I think it maybe ran that next day at 7am but then never again due to know recurrence. Since I’d like it to run every day at that specific time I’m going to set that recurrence and see if that will make it work. I was thinking that would trigger and execute (meet all conditions) the Action multiple times and not just running the backend scheduler multiple times to check the Action’s Conditions each time.
FYI - That was it. Since I’ve added a recurrence of 1 and Unit = Hours the Action has executed the last two hours. So I guess my initial setup ran one time the next day at 7am but never attempted to execute again. Thanks for your help @MGBC