blob: 22b9df5309480818805e503eac589ee21f2a99ef (
plain) (
tree)
|
|
module ActiveRecord
module ConnectionAdapters
module MySQL
class Column < ConnectionAdapters::Column # :nodoc:
delegate :extra, to: :sql_type_metadata, allow_nil: true
def unsigned?
!/\A(?:enum|set)\b/.match?(sql_type) && /\bunsigned\b/.match?(sql_type)
end
def case_sensitive?
collation && !/_ci\z/.match?(collation)
end
def auto_increment?
extra == "auto_increment"
end
end
end
end
end
|