Class: ActiveRecord::ConnectionAdapters::PostgreSQL::OID::Timestamp

Inherits:
Type
  • Object
show all
Defined in:
lib/arjdbc/postgresql/base/oid.rb

Instance Method Summary collapse

Instance Method Details

#typeObject



178
# File 'lib/arjdbc/postgresql/base/oid.rb', line 178

def type; :timestamp; end

#type_cast(value) ⇒ Object



180
181
182
183
184
185
186
# File 'lib/arjdbc/postgresql/base/oid.rb', line 180

def type_cast(value)
  return if value.nil?

  # FIXME: probably we can improve this since we know it is PG
  # specific
  ConnectionAdapters::PostgreSQLColumn.string_to_time value
end