Methods
Attributes
[R] | identity |
Class Public methods
Source: show
# File rails/activerecord/lib/active_record/connection_adapters/sybase_adapter.rb, line 112 def self.binary_to_string(value) # FIXME: sybase-ctlib uses separate sql method for binary columns. value end
Source: show
# File rails/activerecord/lib/active_record/connection_adapters/sybase_adapter.rb, line 89 def initialize(name, default, sql_type = nil, nullable = nil, identity = nil, primary = nil) super(name, default, sql_type, nullable) @default, @identity, @primary = type_cast(default), identity, primary end
Source: show
# File rails/activerecord/lib/active_record/connection_adapters/sybase_adapter.rb, line 108 def self.string_to_binary(value) "0x#{value.unpack("H*")[0]}" end
Instance Public methods
Source: show
# File rails/activerecord/lib/active_record/connection_adapters/sybase_adapter.rb, line 94 def simplified_type(field_type) case field_type when %rint|bigint|smallint|tinyint/ then :integer when %rfloat|double|real/ then :float when %rdecimal|money|numeric|smallmoney/ then :decimal when %rtext|ntext/ then :text when %rbinary|image|varbinary/ then :binary when %rchar|nchar|nvarchar|string|varchar/ then :string when %rbit/ then :boolean when %rdatetime|smalldatetime/ then :datetime else super end end