Oto Shavadze
Oto Shavadze

Reputation: 42863

Regexp in postgresql

What means E here:

regexp_replace('foobarbaz', 'b(..)',  E'X\\1Y', 'g')

?

Upvotes: 0

Views: 99

Answers (1)

Clodoaldo Neto
Clodoaldo Neto

Reputation: 125544

Use the regexp match operator:

select *
from mytable
where col ~ '^.{3}(\d)'

The E denotes a String Constant with C-style Escape

Upvotes: 1

Related Questions