in reply to Re: Map file-glob-style patterns to SQL "LIKE" expressions, with escaping
in thread Map file-glob-style patterns to SQL "LIKE" expressions, with escaping

"It's a trick!"

It's to get longer things to appear before shorter things, so that the "\\" match is preferred over the "\" match, since it'll be first in the list (after a reversed sort). A simple sort-by-decreasing-length would have worked as well, but it takes more to type. :)

-- Randal L. Schwartz, Perl hacker
Be sure to read my standard disclaimer if this is a reply.

  • Comment on Re^2: Map file-glob-style patterns to SQL "LIKE" expressions, with escaping