method
escape_bytea
escape_bytea(s)
private
Hide source
# File activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb, line 376 def escape_bytea(s) if PGconn.respond_to? :escape_bytea self.class.send(:define_method, :escape_bytea) do |s| PGconn.escape_bytea(s) if s end else self.class.send(:define_method, :escape_bytea) do |s| if s result = '' s.each_byte { |c| result << sprintf('\\\\%03o', c) } result end end end escape_bytea(s) end


