Creating Custom Fields with Values Derived from Summary Search Results

You can create a custom field that can display values derived from summary saved search results. Each summary search field displays a rollup value for a selected search results field. The value is dynamically calculated each time a form containing the summary search field is displayed. For example, you can use a summary search field to display the total quantity of all line items on a transaction. The summary search field provides an alternative to using SuiteScript to calculate the values of a custom field.

Note:

Note the following

  • The rollup functionality is similar to that of custom sublists, except the search results display in a field rather than a sublist.

  • To ensure a smoother checkout process for your customers, avoid adding too many values to custom fields.

For details about custom fields with summary search derived values, see the following:

Steps for Creating a Summary Search Custom Field

You can create a custom field with a value derived from a summary search.

To create a custom field with a value derived from a summary search:

  1. Create or edit a summary saved search that rolls up to the result you want to display in the custom field. For more information, see Defining a Saved Search.

    • Add search criteria to filter out any records/lines you don't want included in the rollup value. For more information, see Advanced Search Criteria Filters.

    • Define a search results field for which values will be rolled up, and select a summary type. You can use these summary types: Count, Sum, Minimum, Maximum, and Average. (Group summary type isn't supported.) For instance, you could use Quantity as the results field and Sum as the summary type. For information about summary types, see Summary Type Descriptions.

    • Define an available filter field. The field is used to filter search results to include only those records with available filter field values that match the available filter field value of the current record. The value displayed for the summary search custom field is a rollup of search results field values for the records that have matching available filter field values. For more information, see Selecting Available Filters for Saved Searches.

  2. Create or edit the custom field. For general instructions, see Creating a Custom Field.

    • Select the search on the custom field’s Validation & Defaulting subtab.

    • Optionally, you can select a Compare To field. You can use the Compare To field in cases where you want to place the custom field on a form for a record type that's different from the summary search record type. For example, you may want to place a custom entity field showing the result of a customer record summary search on an employee custom form. To do this, you could select an employee record field whose values could be matched to the values for the search’s Available Filter field. Search results field values for all records with matching values for the Compare To field and Available Filter field would be used to calculate the value of the summary search custom field.

    • Don't enable the Store Value option, because values for rollup custom fields aren't stored.

Custom Fields that Support Summary Search Derived Values

You can select a summary search to provide rollup values for the following custom field types:

  • Entity Fields

  • CRM Fields

  • Transaction Body Fields

  • Other Record Fields

  • Custom Record Custom Fields

Custom Field Data Types that Support Summary Search Derived Values

You can select a summary search to provide rollup values for custom fields of the following types:

  • Currency

  • Date

  • Date/Time

  • Decimal Number

  • Email Address

  • Free-Form Text

  • Hyperlink

  • Integer Number

  • Long Text

  • Percent

  • Phone Number

  • Rich Text

  • Text Area

  • Time of Day

Example Summary Search Custom Field

The following example shows the creation of a custom field to be displayed on custom purchase order forms. The value of the field is calculated by a purchase order summary search that sums the values for the purchase order line items’ Amount field. No Compare To field is needed, because the Internal ID field set as the Available Filter for the search can be matched to the Internal ID of the purchase order record displayed on the form.

Transaction Body Field page with Search and Field highlighted on the Validation & Defaulting subtab.

Current Limitations for Summary Search Custom Fields

  • Custom field values from summary search results are never stored. Field values are always calculated dynamically at runtime. A user may be able to edit values, depending on the display options set for the custom field, but the edited values aren't stored. Also, because its values aren't stored, the field can't be used in search results, including lists based on saved searches.

  • If you have a use case for running a saved search on a formula field where the value isn't stored, there's an alternative solution available. For more information, see Running a Saved Search on a Formula Field Where the Value is Not Stored (SuiteAnswers ID: 1017388).

  • Calculated values for summary search custom fields can vary for users with various permissions. Summary search results are rolled up for the records to which the current user has access. Because users with various permissions can have access to different sets of records, the calculated value of the field can vary per user.

Related Topics

General Notices