class PG::TextEncoder::Date
This is a encoder class for conversion of Ruby Date values to PostgreSQL date type.
def encode(value)
def encode(value) value.respond_to?(:strftime) ? value.strftime("%Y-%m-%d") : value end
This is a encoder class for conversion of Ruby Date values to PostgreSQL date type.
def encode(value) value.respond_to?(:strftime) ? value.strftime("%Y-%m-%d") : value end