DOCUMENT Filter line item references function

The DOCUMENT Filter line item references function in RPA.

Help CentreBuilding Processes

This article describes the RPA Document functionality to filter statement line item references by an example pattern.

For a full list of available functions, please read DOCUMENT functions.


Description

The Filter line item references function cleans up extracted statement data by separating reference numbers from descriptions. You provide an example of what a valid reference looks like, and the function builds a pattern from it: digits in the example match any digit, letters match any letter.

For each line item in the statement:

  • If the reference matches the pattern, it stays in the reference field
  • If the reference does not match, it is moved to the front of the description field, and the reference field is cleared

How patterns work

Example patternWhat it matchesKeeps in referenceMoves to description
2300000Any 7-digit number2416868, 1234567PO10017212, INVRSA123
PO10000000PO + 8 digitsPO10017212, PO998877662416868, INV12345
INVRSA000000006 letters + 8 digitsINVRSA123456782416868, PO10017212

Setting it up

To use the Filter line item references function, follow these instructions:

{{popups:rpas/add:action=statement-filter-reference}}

Once on a process map:

  1. Navigate to the process where you would like to add the function
  2. Click on the green button’s drop-down (right side of the green button labelled “Process”)
  3. On the menu that appears, click on the “+ Activity” item
  4. From here you can select the DOCUMENT Filter line item references option
  5. Click "Add" once you are done

Input parameters

ParameterRequiredTypeDefaultDescription
Reference patternYesText-An example of what the reference should look like. Digits match any digit, letters match any letter. E.g. '2300000' matches any 7-digit number.
VariableYesText-Name of the variable containing the extracted statement data to filter

Output

The function modifies the statement data in place. After filtering:

  • Line items with matching references keep their reference field unchanged
  • Line items with non-matching references have the old reference prepended to description and reference is cleared

Errors

  • Variable not found – the specified variable does not contain statement data
  • Invalid pattern – the pattern example is empty

Tips

  • Run this after extracting statement data to clean up references before reconciliation
  • Use multiple filter steps with different patterns if statements contain mixed reference formats
  • The pattern is case-sensitive for letters: 'PO' matches uppercase only. Use the exact case you expect.

Related functions

See it working on your own data

Everything documented here ships with the platform – try the document tools free, or go live in 7 days.