(PDB-162) Add regexp support to resource parameter queries

The query engine supported this, but the existing "rewrite" rule, to go
from the shorthand parameter syntax to the nested resource query didn't
recognize ~. That is fixed with this commit, so regexps will now work on parameters.
Merge pull request #1000 from senior/ticket/master/pdb-162-regexp-on-resource-params

(PDB-162) Add regexp support to resource parameter queries