diff options
author | Tobias Lütke <tobias.luetke@gmail.com> | 2005-12-24 16:55:55 +0000 |
---|---|---|
committer | Tobias Lütke <tobias.luetke@gmail.com> | 2005-12-24 16:55:55 +0000 |
commit | 87535f50e92f7567d817b455e4f7f4a44371710f (patch) | |
tree | f225d8032f3ef489a7ff84622702488b3fe78cb2 /activerecord/lib/active_record/connection_adapters/abstract | |
parent | ac963f06233d24f26570901a60edabed4792688d (diff) | |
download | rails-87535f50e92f7567d817b455e4f7f4a44371710f.tar.gz rails-87535f50e92f7567d817b455e4f7f4a44371710f.tar.bz2 rails-87535f50e92f7567d817b455e4f7f4a44371710f.zip |
SchemaDumper now doesn't fail anymore when there are unknown column types in the schema. Instead the table is ignored and a Comment is left in the schema.rb also added ActiveRecord::Base.schema_ignore_tables for dealing with funky tables like the tesearch2 ones.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3346 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activerecord/lib/active_record/connection_adapters/abstract')
-rw-r--r-- | activerecord/lib/active_record/connection_adapters/abstract/schema_definitions.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/abstract/schema_definitions.rb b/activerecord/lib/active_record/connection_adapters/abstract/schema_definitions.rb index df79f27576..16a41446a8 100644 --- a/activerecord/lib/active_record/connection_adapters/abstract/schema_definitions.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract/schema_definitions.rb @@ -4,7 +4,7 @@ module ActiveRecord module ConnectionAdapters #:nodoc: # An abstract definition of a column in a table. class Column - attr_reader :name, :default, :type, :limit, :null + attr_reader :name, :default, :type, :limit, :null, :sql_type attr_accessor :primary # Instantiates a new column in the table. @@ -15,6 +15,7 @@ module ActiveRecord # +null+ determines if this column allows +NULL+ values. def initialize(name, default, sql_type = nil, null = true) @name, @type, @null = name, simplified_type(sql_type), null + @sql_type = sql_type # have to do this one separately because type_cast depends on #type @default = type_cast(default) @limit = extract_limit(sql_type) unless sql_type.nil? |