Search Postgresql Archives

Question with combining ANY with ilike

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi PostgreSQL,

I'd like to specify a pattern then apply that pattern to match each element of an array:

rconover=# select 'foobar%' ~~ ANY (ARRAY['bar', 'cat', 'foobar:asdf']);
 ?column?
----------
 f
(1 row)

I'd like the the pattern would be evaluated against all of the array elements, but the order of parameters for the ~~ operator when combined with the ANY command is backwards to what I need.

Do you how I can make it work so that I could write a pattern and match it against the array elements using the ANY command?

Thanks,

Rusty
--
Rusty Conover
rconover@xxxxxxxxxxxxx
InfoGears Inc / GearBuyer.com / FootwearBuyer.com
http://www.infogears.com
http://www.gearbuyer.com
http://www.footwearbuyer.com








--
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux