René Nyffenegger's collection of things on the web
René Nyffenegger on Oracle - Most wanted - Feedback -
 

regexp_substr

regexp_substr (string, pattern)
regexp_substr (string, pattern, position)
regexp_substr (string, pattern, position, occurence)
regexp_substr (string, pattern, position, occurence, parameters)
parameters can be a combination of
  • i: to match case insensitively
  • c: to match case sensitively
  • n: to make the dot (.) match new lines as well
  • m: to make ^ and $ match beginning and end of a line in a multiline string
regexp_substr is an Oracle SQL function that enables regular expressions in queries. It enhances the 'traditional' substr.

Links

See also On splitting a string into words with regular expressions where a function uses regexp_substr to split a string.
Then there is also safe_to_number() where regexp_substr is used to convert strings to numbers.