in reply to Re^2: postgres reg expression quoting
in thread postgres reg expression quoting

Perhaps using quotemeta on the user's input before you supply it to DBI's execute method?


Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
"Too many [] have been sedated by an oppressive environment of political correctness and risk aversion."

Replies are listed 'Best First'.
Re^4: postgres reg expression quoting
by zdzieblo (Acolyte) on Apr 01, 2009 at 14:44 UTC

    that smells like a solution, quotemeta will add '\' to all non word characters and then during execution that '\' will get quoted to make it '\\' so postgress is happy