Extract Text

Pull one piece out of a text column. Take the first letters, or the part after a symbol.

What it does

Extract Text copies part of a value into another column. You choose how to find that part. Eight methods cover the common cases. The original column is left alone.

Think of a delivery file with an order reference like IN-2026-0043 and a customer email. This page uses both.

Extract a piece of text

  1. Type extract text in the Search transforms box, in the Pipeline panel.
  2. Select Extract Text in the results.
  3. Open Select column and pick your column.
  4. Open Extraction method. It starts on position.
  5. Fill in the boxes that appear. The panel only shows the boxes your method needs.
  6. Type a name in New Column Name, under Apply results into.
  7. Click Apply.

The eight methods

MethodBoxes it showsWhat you get
positionStart position, LengthA slice that starts at the character you name. The first character is number 1.
starts_withNumber of charactersThat many characters from the left end.
ends_withNumber of charactersThat many characters from the right end.
before_delimiterDelimiterEverything in front of the first delimiter.
after_delimiterDelimiterEverything behind the first delimiter.
between_delimitersDelimiter, Second delimiterThe text between the two markers.
contains_numberNoneThe first run of digits in the value.
regexRegex patternThe whole piece of text that your pattern matches.

A delimiter is any marker you type. It can be a comma, a dash, an @ sign, or a whole word.

Four worked examples

  • Country code from IN-2026-0043: choose starts_with and set Number of characters to 2. You get IN.
  • Order year from IN-2026-0043: choose position, set Start position to 4 and Length to 4. You get 2026.
  • User name from priya@acme.com: choose before_delimiter and type @ in Delimiter. You get priya.
  • Mail domain from priya@acme.com: choose after_delimiter and type @. You get acme.com.

A delimiter method finds nothing when the marker is absent. Those rows get an empty value.

Where the extract lands

Set the target under Apply results into.

  • New Column (Text) adds a text column at the end of the table.
  • Existing Column overwrites a column you pick from the list.

Leave New Column Name empty, and the app names the column for you. It uses your source column name plus _extract.

Extract from some rows only

Click Add Condition and build a test, such as channel is web. Click Apply Condition. Rows that fail the test get an empty value.

Two notes on the regex method

  • It returns the whole match. Brackets in your pattern do not split the result. Use Regex Capture when you need several pieces at once.
  • A Generate regex from intent helper sits above the pattern box. Describe the piece you want in plain words. The helper needs an API key in Settings.

The SQL it runs

The before_delimiter example runs as:

SELECT *, SPLIT_PART("customer_email", '@', 1) AS "user_name" FROM data
Try Extract Text with sample data →

Related Operations