Skip to content
Release: Australia · Updated: 2026-03-12 · Official documentation · View source

Matrix Loader: CSV rules upload

Use the Matrix Loader to bulk create, edit, and export rules in ServiceNow CPQ. Define rule conditions, actions, and logic in a CSV file to streamline configuration management and automate large-scale updates.

The the Matrix Loader enables administrators to efficiently upload and manage all rule types in ServiceNow CPQ. Instead of manually creating each rule in the Admin interface, you can define them in a spreadsheet, export the sheet to CSV format, and upload it directly into the environment. This enables faster configuration setup, easier testing, and simplified migration between sandbox and production environments.

Rules upload structure

Each row in the CSV file represents a rule record. The following table outlines the columns and data that the Matrix Loader accepts for rule uploads.

Column NameDescriptionValid ValuesNotes
record_typeIdentifies this as a rule uploadruleRequired
rule_nameName displayed on the rule list Admin pageValid strings can be composed of up to 255 characters, including letters, numbers, spaces, and the following special characters: {}[]()|\~_^@?<=>;:/.-,+*’&%$#”!`Required
rule_variable_nameUnique string used by ServiceNow CPQ to reference the ruleValid field variable names consist of up to 128 letters, numbers, and underscores. The first and last character must be a letter or number.Required; must be unique
rule_descriptionContextual description for administrator referenceValid strings can be composed of up to 255 characters, including letters, numbers, spaces, and the following special characters: {}[]()|\~_^@?<=>;:/.-,+*’&%$#”!`Optional
rule_statusDetermines if the rule is activeactive, inactiveRequired; inactive rules are ignored by the engine
action_typeDefines the type of action executed when the rule runsvisibility, message, exclusion, inclusion, determination, productRequired
action_sub_typeSupplementary definition augmenting action_typehide, info, warning, error, hidden, disabled, set, forceset, manufacturing, salesOptional; depends on action_type
action_fieldField to which the action applies<field variableName>Required
action_valueValue applied to the action_fieldVaries by action typeRequired for message, exclusion, inclusion, or determination actions
action_productProduct reference for bill-of-material (BOM) actionsSFDC Product Code, Product2 ID, or External IDRequired for product actions
action_quantityQuantity of the product added to the BOM<positive float> or <positive integer>Required for product actions
action_mandatorySpecifies whether a BOM product is optional or mandatoryTRUE, FALSE, <empty>Optional; defaults to TRUE
groupingDefines how conditions are grouped and evaluatedany, all, custom, alwaysRequired
resource / operator / valueDefines condition tuples forming the rule logic<field variableName>, operator, valueResource, operator, and value together define the condition expression

Condition groupings

Condition groupings determine how rule conditions are logically combined. Supported options include:

  • any: ORs all conditions defined in the row.
  • all: ANDs all conditions defined in the row.
  • custom: Allows complex logic expressions, such as (1 OR 2) AND 3.
  • always: Applies the rule unconditionally.

Valid operators

The following operators are supported for condition evaluation:

  • equals (=, ==, equals)
  • not equals (!=)
  • less than (<)
  • less than or equal
  • greater than (>)
  • greater than or equal (>=)
  • contains / not contains
  • in / not in

General guidelines

  • Always verify variable names match the field references exactly.
  • Keep rule descriptions concise but descriptive to aid troubleshooting.
  • Use inactive status for testing new rules before enabling in production.
  • Validate grouping logic (any/all/custom) carefully to avoid unintended outcomes.
  • Ensure product references (Product2 ID or External ID) align with your Salesforce configuration.

Exporting rules to CSV

Administrators can export all rule definitions from the ServiceNow CPQ environment to CSV format for review or migration. The resulting ZIP file contains a single CSV file of all exported rule definitions.

  1. In the left Admin navigation pane, click Rules.
  2. Optional: enter a search string and press Enter to narrow results.
  3. Click Export. A message confirming export appears at the bottom of the page.
  4. Open the Notification Center (bottom left) and click the Download link.

Additional information

  • Valid strings may include letters, numbers, spaces, and special characters: { } [ ] ( ) | \ ~ _ ^ @ ? < = > ; : / . - , + * ’ & % $ # "`
  • Rule variable names can contain up to 255 alphanumeric characters and underscores. They must begin and end with a letter or number.
  • Cells with gray backgrounds in sample files denote irrelevant fields for the current context.
  • Use the provided sample files (Admin → Matrix Loader → Sample Files → Rules) as a template for formatting.

Related topics

Configure the Matrix Loader

Matrix Loader: CSV rules upload