Re: Doing a regexp-based search/replace?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Steve Frampton <frampton(at)LinuxNinja(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Doing a regexp-based search/replace?
Date: 2001-10-18 18:52:46
Message-ID: 25088.1003431166@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin pgsql-sql

Steve Frampton <frampton(at)LinuxNinja(dot)com> writes:
> If this were a text file, I would use a sed expression such as:
> cat textfile | sed 's/-.*$//'
> I've been looking for a way to do this with PostgreSQL but so far haven't
> found a function that seems to be suitable.

Write a function in pltcl or plperl, either of which can mash text
strings with ease and abandon ...

regards, tom lane

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Tom Lane 2001-10-18 19:08:08 Re: delete/vacuum not freeing disk space
Previous Message Brett Schwarz 2001-10-18 18:30:23 Re: Doing a regexp-based search/replace?

Browse pgsql-sql by date

  From Date Subject
Next Message Stephan Szabo 2001-10-18 19:14:08 Re: update in rule
Previous Message Brett Schwarz 2001-10-18 18:30:23 Re: Doing a regexp-based search/replace?