Larry Woo
Senior NetSuite Consultant
Anyone who’s ever created a NetSuite Workflow has probably encountered a scenario where you need to use a Saved Search to trigger a workflow action or initiate a workflow, and this works very well. At times, the business logic may require you to look at a summary result of the search (for example: counting records, looking for a summed value, etc.), this is where you’d notice that NetSuite doesn’t respond as expected because it looks at the full result of your search and not the summarized view that one would see through the user interface. So how does one overcome this by still using the summarized results of your single search?
First, we need to create a Summarized Save Search in the system to display the result or variable that you wish to monitor to determine if the workflow should take any action. Here are some quick points about this Save Search:
Second, create a custom field that matches the save search record type (for example: if your summary search is a customer search, you’ll need to create a custom entity field). Set up your field as a Free-Form Text, uncheck “Store Value”, and under the “Validation & Defaulting” tab select your summary search in the search dropdown. The key here is to not store the value, NetSuite will execute and provide the workflow with the latest information to trigger the workflow.
Also, make the field display ‘inline’ so the value does not get tampered with.
Now you have a triggering mechanism for your workflow to use for your workflow action. In my example, I have a customer workflow that checks to see if there are a specific number of open opportunities for that customer and if it reaches the threshold it will display a button that would lead to another record being created.
So depending on your specific outcome, there’s hope if you need to look at a summary data set to make your workflow automation perform its duty, without the need for custom scripting. This also gives you greater control over the thresholds, as the save search just needs to be updated or adjustments made to your workflow through the user interface.
Want to learn more? Reach out to our NetSuite experts today!
NetSuite
Using a Summary Saved Search to Trigger a Workflow in NetSuite