Custom Segments as Fields

When a custom segment has been applied to a record type, your workflow can reference the segment as it would any of that record type’s fields. For examples, see the following sections:

Setting Field Values

If appropriate, you can use the Set Field Value action to populate a custom segment field with a value. This approach can be an alternative to using the custom segment’s Source List field (which is described in Dynamic Default Value Sourcing for Custom Segments). Compared with the Source List field, the Set Field Value action allows for greater granularity when configuring the behavior of defaults.

For example, with a workflow, you can set a distinct sourcing method for each specific record type. By contrast, in some cases, the custom segment’s Source List field lets you choose only one defaulting method, and that method is shared by multiple record types. For example, you can select only one Source List value for all transaction types. However, with a workflow, you could use the Set Field Value action to create a unique defaulting method for each specific transaction type.

For example, suppose you were editing a workflow that affects the Cash Sale transaction type. For this example, assume also that you have a custom segment called Sales Region that has been applied to both the Cash Sale transaction type and the Customer record type. You may want the Sales Region value used on each cash sale to match the value of the segment as it appears on the corresponding customer record.

To configure this behavior, use the fields under the Parameters heading in the Workflow Action window. You identify the segment for which you want to create the default by using the Field list on the left side of the page, then use the fields under the Value heading to configure the sourcing behavior. Specifically, you select the From Field radio button. Then you use the Record list to identify the record that will provide the default value. Use the Field list to identify the source field.

Example of setting segment field values.

The Set Field Value action also provides multiple options for determining when the segment field will be populated with a default value. By contrast, when you use the custom segment’s Source List field, the segment is populated with the default value only when the value of the source field is set or changes. Typically, this event takes place when the user opens a new record, if NetSuite populates the source field automatically, or when the user is editing the record. With a workflow, you could configure the value to be populated at various times, including after the user clicks Save and is no longer looking at the record. You configure this behavior in the Workflow Action window. Specifically, you use the Trigger On list.

Sample segment Workflow Trigger On list.

Similarly, with a workflow, you could choose to have the segment value be set only when the record is updated, rather than when it is created. Conversely, you could choose to have the segment value be set only when the record is created, rather than when it is updated. You do this by editing the workflow and making choices under the Event Definition heading.

Sample segment Workflow Event Definition with On Update box checked.

For full details on the Set Field Value action, see Set Field Value Action.

Setting Workflow Conditions

Another time you may want to refer to a segment as a field is when setting workflow conditions. For example, you could create a condition that a workflow runs if the segment is set to a certain value only. In this case, open the Workflow Condition window as you would when setting any condition. In the Field list, select the name of the segment. In the Value column, add the specific text that you want to reference. For example, in the following screenshot, a condition dictates that a workflow will run only when the Sales Region segment is set to the value Lima.

Sample segment Workflow Condition page.

For more information on workflow conditions, see Workflow Conditions.

Related Topics

Using Custom Segments in Workflows
Records that Represent Custom Segment Values

General Notices