matching against a list of regexp?
matching against a list of regexp?
От:
"Gauthier, Dave" <dave.gauthier@intel.com>
Дата:
Hi:
I need to be able to select all records with a col value that matches any of a list of regexp. Sort of like...
select a,b,c from foo where d ~ ('^xyz','blah','shrug$');
Does anyone know the right syntax for this?
Thanks!
Re: matching against a list of regexp?
От:
Richard Broersma <richard.broersma@gmail.com>
Дата:
On Thu, Oct 27, 2011 at 9:18 AM, Gauthier, Dave wrote:
> I need to be able to select all records with a col value that matches any of
> a list of regexp. Sort of like...
>
> select a,b,c from foo where d ~ ('^xyz','blah','shrug$');
WHERE d ~ '^xyz|blah|shrug$'
--
Regards,
Richard Broersma Jr.