I have created a Workflow which should run wheneve...
# suiteflow
j
I have created a Workflow which should run whenever one of a particular type of Custom Record is created, however it doesn’t seem to ever run. Any suggestions on what I might be overlooking here? Nothing is selected under
CONTEXTS
should it should run in all contexts. I also tried having
TRIGGER TYPE
set to ‘- All -’ and it didn’t run then either.
t
What does it look like on the record under system information in the logs?
j
it’s not there, because it didn’t execute.
nothing under Active Workflows or Workflow History. It doesn’t seem to be executing at all.
saved search of instance history turns up nothing also
welp. Seems it doesn’t run when the record is created by UserEvent (which is the usual method by which this custom record is created).
the UE runs on transaction, creates the custom record. That custom record being created does not trigger the WF…..
j
What is the trigger type on the workflow actions?
e
WF setup looks OK... ¿How is the Action set up?
m
Records created by a User Event Script don't trigger workflows, same way a UE won't trigger another UE (to prevent endless loops)
👍 1
j
Yeah I’m realising this now 😞
m
@jen you could setup your workflow to run as a scheduled workflow. You could make a checkbox on your custom record called "Record Processed" or whatever you like. Then make a saved search of custom records where Record Processed = F. The run your actions and lastly check the Record Processed box to clear it from the list. It can run up to every 30 min, so not exactly realtime, but every 30 min is pretty quick considering how fast a day goes by...LOL
☝️ 1
Just a thought as it would get around the UserEvent -> UserEvent problem
j
I did consider that, but unfortunately the name I’m generating is the Policy Number for insurance policies, so it kinda has to generate itself immediately. It’s ok, I’ve got a script in place to just edit->save again with the generated name.
n
What if you shift your record creating logic in to a Suitelet and call that from the UE? Speculating he WF should fire then. (I rarely go near WF's)
z
@jen it's rule for User events in NetSuite: it will be triggered only for top level, on record that is created/updated, but will not for records created - updated within top level... I would create workflow action script and deploy it on the TRANSACTION. Then create workflow for TRANSACTION on before-after submit event, add state which invoke workflow action...