Creating a custom field that pulls results from a saved search in NetSuite

By - February 25, 2020

This is a NetSuite tip on adding a custom field that uses a saved search to pull the results from. First, we need to create a saved search that the field uses for the results. And then we will create a custom transaction body field on a Sales Order to show the total of quantity of all the items that is on that Sales Order.

To create a saved search, we navigate to Transactions > Management > Saved Searches > New

On the Criteria tab, we set the type of transaction is ‘Sales Order’. We eliminate the Main Line, Tax Line and Shipping Line so only see the actual Item lines. This way we will get an accurate sum.

Search for total quantity on sales order

On the Results tab, all we want here is the value that is going to go to the saved search which is Quantity and we’re summarizing that quantity.

On the Available Filters tab, we give it a filter field that it knows how to connect to the data we’re looking at.

Save the search.

Next, we create a custom transaction body field on Sales Order by navigating to Customization > Lists, Records & Fields > Transaction Body Fields > New. And we name it ‘Total Quantity on SO’ and apply to Sales. Choose the type of Integer Number and uncheck the Store Value checkbox.

Transaction body field

Then on Display tab, we set the field to be displayed on the Main tab.

On Validation & Defaulting tab, we select the Saved Search we just created earlier by selecting it from the Search drop down box.

Save the record.

Next, refresh one of the Sales Order and we should see the field ‘Total Quantity on SO’ to be updated.

Sales order

If you are interested in creating a saved search to show a latest edit to a record using System Notes field, please refer to this post.

Thanks for reading about how to create a custom field that uses calculated data from a saved search. If you would like more information on this topic or others related to NetSuite, please reach out to RSM’s NetSuite professionals by contacting us at NetSuite@rsmus.com or call 855.437.7202.

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *

Receive Posts by Email

Subscribe and receive notifications of new posts by email.