text

regexp_replace

Replaces the first matching substring by default; g replaces all matches. Replacement text can reference captures.

Formal Syntax & Structure

sql syntaxsql
regexp_replace(string, pattern, replacement [, flags])

Working Example

Example Snippetsql
SELECT regexp_replace('x12 y34', '[0-9]+', '#', 'g');
SQL Reference