Skip to content

Instantly share code, notes, and snippets.

@beanieboi
Created September 2, 2011 12:07
Show Gist options
  • Save beanieboi/1188453 to your computer and use it in GitHub Desktop.
Save beanieboi/1188453 to your computer and use it in GitHub Desktop.
scope :case_insensitive_email, lambda { |email| where("email ILIKE ?", email) }
request parameters: {"email"=>"foo\\"}
PGError: ERROR: LIKE pattern must not end with escape character
: SELECT "users".* FROM "users" WHERE (email ILIKE 'foo\') LIMIT 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment