Text: Find text next to other text

Use this action to find a string within a text block based on its position or relationship to other text.

Use case

Use this action in combination with other text actions to manipulate text with Workflow. This action can be part of a larger text manipulation process that can help with a number of cases:

  • Change the company name on a contract in all places
  • Update an invoice order based on a supplier request
  • Strip line breaks, spaces, or special characters out of a block of text
  • Perform text substitution instead of writing complex REGEX codes

How to configure this action

Use the type and value fields to create complex searches. The Start or End Type will modify the chosen start or end value. For example, the after-text Start type will return any result after the text specified in Start value. The End type and End value fields will return results before or not past a specific value.

Example of how to search for all totals on an invoice

Here’s an example of how to search the following text from an invoice and return the totals from each row, but not the estimate or number of inquiries.

Estimate: $500
Subtotal: $1000
Tax Total: $100
Grand total: $1100
Inquiries: 40
  1. Enter Start type: after-text and Start value: total:
  2. Enter End type: line-end and leave End value: blank.
  3. This will search the Text to Search content for all text that’s between total: and the end of any line.
  4. The result will be $1000, $100, and $1100, as each of these result are after total: and before the end of the line. It will not return the values after estimate or inquiries because it did not meet the defined criteria.

Fields for this action

    • Enter a block of text or field reference to text. This is the text that will be searched through.
  • Output field name

    • The name of the data table in which the result should be saved. In addition, the first match found will be returned in a field called {{output field name}}—first-match
  • Start type

    • Select the start type option to use for the search. The start value selected below will use this query for the search. Start type and the start value define the beginning of the text to be returned. Enter one of these options:
  • Type options Type effect Start value example
    after-text after specific text Total:
    before-text before specific text .com
    after-lines after X number of lines {{field-name}}
    after-characters after X number of characters 10
    after-words after X number of words 2
    after-paragraphs after X number of paragraphs 4
    start-of-text from the beginning of the text  
  • Start value

    • Together, the start type and the start value define the beginning of the text you want to find. Enter the value based on your start type. This may be text, a number, or a field reference depending on the start type.
  • End Type

    • Select the End type option to use for the search. The End value selected below will use this query for the search. End type and the End value define the end of the text to be returned. Enter one of these options:

    • Type options Type effect End value example
      after-text after a certain word USD
      before-text before a certain word {{field-name}}
      line-end end of the line <no value needed>
      word-end end of the word <no value needed>
      paragraph-end until the next empty line <no value needed>
      after-lines after X number of lines {{field-name}}
      after-characters after X number of characters 10
      after-words after X number of words 2
      after-paragraphs after X number of paragraphs 4
      end-of-text at the end of the text  
  • End value

    • Together, the end type and the end value define the beginning of the text you want to find. Enter the value based on your end type. This may be text, a number, or a field reference depending on the end type.
  • Case sensitive

    • Select True or False from the drop down to set case sensitivity.
      • Select True to match the case of between the search value and the Text to search.
      • Select False or leave blank to make your search case insensitive.

What will this output?

This action may generate multiple fields. To help keep output fields organized, the prefix above will be added to the beginning of each of the output field names, separated by two dashes. Each field will result as:{{output-field-name--output-field}}.

Output fields for this action

  • Output field name data table

    • The data table where all matched results will be stored. The field name is defined in Output field name during configuration. The table will have 2 columns:

    • Matching Text Position
      The text that matched the search value. The position of the matching text in the text body using a #,# syntax where the first value is the row #, and the second is the character # in the row.
  • First match

    • Returns just the first match of the action. The remaining matches are stored in the associated data table.
  • First match position

    • Returns the position of text from the first match using a #,# syntax.

Sorry about that. What was the most unhelpful part?









Thanks for your feedback

We update the Help Center daily, so expect changes soon.

Link Copied

Paste this URL anywhere to link straight to the section.

Need more help?

If you're signed in to Catalytic Community, you can ask other users a question. You'll be redirected to Community where you can add more info.