Preparing Entities for Synchronization: Filtering

In this topic, you will learn how you can define export and import filtering settings.

Export Filtering

You can configure the rules according to which data from MYOB Advanced should or should not be exported to the online store by using the Export Filtering tab of the Entities (BC202000) form.

To define a filter, you need to specify at least one filtering condition. Each condition includes the following components:

  • Field Name: The data field by which data needs to be filtered. The list of options you can select from depends on the selected entity.
  • Condition: The logical operation to apply to the value of the selected data field.
  • Value: The value you enter for the logical condition used to filter the data, if the selected condition requires a value.
  • Value 2: The second value for the logical condition, if the selected logical condition requires a second value. For example, the Is Between logical condition requires a second value.

A filter may contain multiple simple conditions or lines combined into one logical expression with brackets and logical operators (And and Or).

Example

Suppose that you want to maintain customers of a particular customer class, INTL, only in MYOB Advanced, and you want to exclude such customers from synchronization with the BigCommerce store. To do this, you select the Customer entity in the Summary area of the Entities form, and on the Export Filtering tab, you specify the condition corresponding to the settings shown in the following table.

Active Brackets Field Name Condition Value Value 2 Brackets Operator
Selected - Customer Class Does Not Equal INTL Empty - And

The particular fields that you can select in the Field Name column depend on the selected entity.

Note: If you change the export filter settings after an export has been completed, the synchronization records that have been previously processed and are no longer included in the filter, will remain synchronized but will be assigned the Filtered status.

Export Filtering by Custom Fields

Export filtering by custom fields, which are fields added to a form as a result of publishing a customization project, is available for the Customer, Stock Item, Non-Stock Item, Template Item, and Sales Order entities.

To use a custom field in a filtering condition, on the Export Filtering tab of the Entities (BC202000) form, you should type the name of the field in the Field Name column of the table. The system validates the field name against the API field list and displays an error if the field name cannot be found.

Tip:

To avoid typing errors, you can copy the name of the needed field from the API Advanced list as follows:

  1. On the Export Mapping tab, in the ERP Object column, select the <Entity> → Advanced option.
  2. In the ERP Field / Value column, click the down arrow, and then select and copy the needed field name.
Attention: In some situations, a custom field used in a filtering condition may become unavailable during export, for example, if a customization project that added the field has been unpublished. In this case, the system will treat the value in the condition that contains the missing field as null. To avoid issues during the export, the Is Not Empty condition should be added to each filtering condition that includes custom fields.

Export Filtering by Attributes

Export filtering by attributes is available for the Customer, Stock Item, and Non-Stock Item, and Template Item entities.

When an attribute is created and added to a customer class or item class, it becomes available for selection on the Entities (BC202000) form. To use an attribute in a filtering condition, you should select it in the Field Name column of the table on the Export Filtering tab. An attribute can be distinguished from other fields by the Attributes prefix before its name.

Attention: In some situations, an attribute used in a filtering condition may become unavailable during export, for example, if an attribute has been removed from an item class or a customer class of an item or a customer, respectively, being exported. In this case, the system will treat the value in the condition that contains the missing field as null. To avoid issues during the export, the Is Not Empty condition should be added to each filtering condition that includes attributes.

Import Filtering

You can configure the rules according to which data from the online store should or should not be imported into MYOB Advanced by using the Import Filtering tab of the Entities (BC202000) form.

To define a filter, you need to specify at least one filtering condition. Each condition includes the following components:

  • Field Name: The data field by which data needs to be filtered. The list of options you can select from depends on the selected entity.
  • Condition: The logical operation to apply to the value of the selected data field.
  • Value: The value you enter for the logical condition used to filter the data, if the selected condition requires a value.
  • Value 2: The second value for the logical condition, if the selected logical condition requires a second value. For example, the Is Between logical condition requires a second value.

A filter may contain multiple simple conditions or lines combined into one logical expression with brackets and logical operators (And and Or).

Example

Suppose that you do not want to import into MYOB Advanced orders placed in the online store by a particular customer, Morning Cafe. To do this, you select the Order entity in the Summary area of the Entities form, and on the Import Filtering tab, you specify the condition corresponding to the settings shown in the following table.

Active Brackets Field Name Condition Value Value 2 Brackets Operator
Selected - Customer Does Not Equal Morning Cafe Empty - And

The particular fields that you can select in the Field Name column depend on the selected entity.

Note: If you change the import filter settings after an import has been completed, the synchronization records that have been previously processed and are no longer included in the filter, will remain synchronized but will be assigned the Filtered status.