Skip site navigation (1) Skip section navigation (2)

regexp_replace

From: "Marcin Krawczyk" <jankes(dot)mk(at)gmail(dot)com>
To: pgsql-sql(at)postgresql(dot)org
Subject: regexp_replace
Date: 2008-08-01 11:22:40
Message-ID: 95f6bf9b0808010422q4a16b3balc19790de5328e267@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-sql
Hi all. I'd like to know whether it's possible to reverse the
behaviour of regexp_replace, meaning :
now if I do
SELECT regexp_replace ('foobarbaz', 'b..', 'X') I get 'fooXbaz' - it
replaces the string that matches given pattern with 'X', how do I
achieve the opposite - replace the string that doesn't match the
pattern ?

regards
mk

Responses

pgsql-sql by date

Next:From: Pawel SochaDate: 2008-08-01 12:14:35
Subject: Re: regexp_replace
Previous:From: Marcin StępnickiDate: 2008-08-01 10:42:01
Subject: Re: How to change a view's owner in postgres

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group