Anyone here a SuiteFlow expert? I posted a questio...
# general
p
Anyone here a SuiteFlow expert? I posted a question last night and wondering if anyone had a suggestion.
a
Hi There, I can help you with SuiteFlow, but I missed your question
p
I am working on doing some task automation for my company. I am new to Netsuite so really just figuring things out. What I am trying to achieve is updating the status of a customer when a child task is completed. I figured the easiest way to do this is a saved search. For testing, I set up the workflow to initiate by event using the saved search as the condition. In the state, I just have an action that triggers on entry and is supposed to update a field.
In the workflow history when I update the task, it shows up in the saved search as it should. The workflow triggers and I can see the entries in the history tab. The issue is that the actual action is not triggering. Am I missing something? I have been trying to figure this out for about 6 hours now and just have no idea what I am missing. Any help would be greatly appreciated.
a
So the action is a Set Field Value action on the Customer Status field?
p
What I am hoping is that when the user click complete, this adds the customer record to a saved search. That part works. When that record shows up on the saved search, workflow updates the status of the customer. When the status updates, it should remove it from the saved search automatically based on my criteria. The part that doesnt work is the trigger when the record is added to the search.
I can see the entries, the action just doesnt fire
a
Can you send me a screenshot of your workflow state that has the action in it?
p
State
a
Also I can't see from your picture but is there a "Log" link in your workflow history tab?
p
No which is a whole other issue lol
Workflow
a
Can you enable Logging?
p
I cant find the Workflow Execution Log button anywhere
It is enabled
a
Your workflow config should look like this
message has been deleted
p
Yup thats how I have it
a
Then under the workflow history you should have this coulumn
message has been deleted
p
It doesnt show for me at all.
Im dumb
I was looking at my non-admin role haha
message has been deleted
a
So the action that is not working is the Set Field Value action of setting the Phone field?
p
Correct here is the log entry
a
Does it say "cannot perform action BEFORELOAD" or something like that?
p
message has been deleted
a
Ok one problem is you are only firing this action on CREATE. so it will only try to set the field value when a new customer record is created
I'm guessing that these customer records are already created so you would want to change that in the Event Types
Just edit your set field value action and then Ctrl + Click on the "Create" value under Event Types, which should de-select it
p
Sets it to all
a
or that
p
message has been deleted
a
ok now try again
and lets look at the logs after this attempt
p
message has been deleted
a
Ahh there it is the dreaded cannot set BEFORELOAD error
this always happens
So at least we've made progress, your action is trying to fire, but just can't because your Trigger is Entry
p
Right and I set that because NS docs said to
a
Right, so we can make a different way to do this, but I need to understand what you are trying to do a little more
p
So I have a task that is assigned to a company record (customer)
When I click complete, the team wants to change the status of the company. Think of it like a project and changing status'
a
Ok so your saved search is looking for customer records where your Task status = Complete?
basically
p
Correct
Its a customer saved search looking at the task relations
a
Ok so unfortunately your only option might be to use a scheduled transition or ttrigger
Is updating this status every 30 min accepatable?
Actually it would be every 1 hr to 1.5 hrs....is that okay?
p
They are sales people and asked for instant
How would a trigger work?
Like a script?
a
Hmm let me think for a minute. To trigger it instantly someone needs to interact with the record you want to change (ie the customer record)
Because a WF can only update field values if someone interacts directly with the record OR on a schedule
p
Ah ok. I have no idea how to write a script to do this to be honest.
a
i might have a solution here, let me think of one more thing we can try
p
Alright. Thank you for your help so far. It is appreaciated.
a
no problem
Would you be willing to share a screenshot of the entire workflow showing all the states?
p
message has been deleted
message has been deleted
message has been deleted
a
And the Set Field Value Action of setting the Phone field is in the Create Task state?
p
It is. It essentially auto transitions to the second state
a
Can you send me a screenshot of the transition from WR002 to Create Task?
p
Should be above
The second screenshot
a
ok sorry
i see it now
So it transitions whenever it meets the saved search criteria
p
Yup
and we can see that in the workflow log
a
Well you've set this up pretty well so far, but unfortunately we are running into a limitation of Netsuite where it will do some actions in the "backgrond" based on Saved search conditions but it can't do everything
So it can do transitions, or possible set WF fields things like that
but it can't atually do anything to change fields on the record because the record needs to be Loaded from the database and saved to get changes to take effect
p
I set it to scheduled for the time being just to make sure it updates
a
If you are will to work with a Scheduled update (the most frequent it can be is every 30 min) then we can do this pretty easily in a WF
otherwise I don't know it will be possible......
p
If I did it as a script, I assume we could trigger it automatically?
a
yes
you could use a script or a custom workflow action
(which is basically a script triggered from a WF)
p
I'll have to learn the workflow actions.
a
If you want I know there is one company that made a bundle that would have a solution for this
Essentially you can update fields on a record from a joined record. (In your example you would make a Task WF that would update the related customer record from the task)
then it could happen in realtime
p
NIce is that yours?
a
A friend of mine built it
It's a pretty neat little bundle
p
Awesome. Going to look into getting it. I am assuming it has generic actions to do some of the stuff I am needing?
a
Yes all the actions are very "genearic" and versitle so they can be used in many different instances
p
Just purchased
Have you set it up previously?
a
Yes I've walked through it before on most of the actions