Escape rather than filter SIMILAR TO metacharacters in patron crazy search
authordbs <dbs@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 14 Apr 2011 18:24:42 +0000 (18:24 +0000)
committerdbs <dbs@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 14 Apr 2011 18:24:42 +0000 (18:24 +0000)
commitad52fbab561af149208d95e4b5c48caa926523aa
tree8df6e1ecadaf829a0dcc7d0ce0dc848495d40dba
parentaae4d157f1f920a6957ad47e59f9714183b283a4
Escape rather than filter SIMILAR TO metacharacters in patron crazy search

The filtering I introduced in r19983 was overly aggressive, and included
characters that weren't actually SIMILAR TO metacharacters. Instead, escape
each character, carefully going through the list of metacharacters listed at
http://www.postgresql.org/docs/8.4/interactive/functions-matching.html

Works for email addresses like "foo.bar+baz@example.com".

git-svn-id: svn://svn.open-ils.org/ILS/branches/rel_2_0@20087 dcc99617-32d9-48b4-a31d-7c20da2025e4
Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/actor.pm