Escaping parenthesis in regular expressions....

From: "Steve Wolfe" <steve(at)iboats(dot)com>
To: "Pgsql-General" <pgsql-general(at)postgreSQL(dot)org>
Subject: Escaping parenthesis in regular expressions....
Date: 2000-07-14 18:00:57
Message-ID: 00af01bfedbd$77fe0040$85755ad1@iboats.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


How does one escape parenthesis in a regular expression in Postgres?

An example is:

select * from subcategories where subcategory ~* '401(k)';

Which does not work. I've tried:

select * from subcategories where subcategory ~* '401\(k\)';

That still didn't work. Any advice would be much appreciated. BTW,

select * from subcategories where subcategory = '401(k)';

does work. ; )

steve

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Yves Dorfsman 2000-07-14 18:19:38 Re: Postgresql and Postmaster response
Previous Message Sean Alphonse 2000-07-14 17:51:27 Solved Problem for Postmaster