IBM Seedlist Connector 25.1
IBM Seedlist Connector Help

# regex_replace_all

Searches a string for matches to a regular expression, and replaces the matches according to the value specified by the `replacement` argument.

## Syntax

    regex_replace_all( input, regex, replacement )

## Arguments

Argument | Description
--- | ---
`input` | (string) The string in which you want to replace values.
`regex` | (string) The regular expression to use to find values to be replaced.
`replacement` | (string) A string that specifies how to replace the matches of the regular expression.

## Returns

(String). The modified string.

## Examples

    regex_replace_all("ABC ABC ABC", "AB", "A")
    -- returns "AC AC AC"

    regex_replace_all("One Two Three", "\\w{3}", "_")
    -- returns "_ _ _ee"

    regex_replace_all("One Two Three", "(\\w+) (\\w+)", "\\2 \\1")
    -- returns "Two One Three"

Copyright 2024 Open Text
Version 25.1 | Last updated January 2025

Send documentation feedback

Close

Send documentation feedback

To send feedback using your default email client, open an email window.

Otherwise, send your feedback and the information below to MFI-swpdl.idoldocsfeedback@opentext.com.

We appreciate your feedback!

Product: Knowledge Discovery IBM Seedlist Connector 25.1

Topic Title: regex_replace_all