I have the following error when issuing a regexp match operation in pg connection:
model.where("? ~* #{field}", value.text).order(code: :desc).to_sql
# => "SELECT \"purchases\".* FROM \"purchases\" WHERE ('c2b32596-c0cc-4157-b007-1c3dbcf5f4be' ~* source_guid) ORDER BY \"purchases\".\"code\" DESC"
the error text:
output error: java.lang.NoSuchMethodError: org.jruby.RubyEncoding.newEncoding(Lorg/jruby/Ruby;Lorg/jcodings/Encoding;)Lorg/jruby/RubyEncoding;