last of the auto_increments removed from the migrations

This commit is contained in:
Andy Allan 2008-11-08 17:39:16 +00:00
parent 9432e7ce27
commit c19d1b406b
3 changed files with 5 additions and 3 deletions

View file

@ -199,7 +199,7 @@ class CreateOsmDb < ActiveRecord::Migration
add_primary_key "way_segments", ["id", "version", "sequence_id"]
change_column "way_segments", "sequence_id", :bigint, :limit => 11, :null => false, :options => "AUTO_INCREMENT"
change_column "way_segments", "sequence_id", :bigint_auto_11
create_table "way_tags", myisam_table do |t|
t.column "id", :bigint, :limit => 64, :default => 0, :null => false
@ -221,7 +221,7 @@ class CreateOsmDb < ActiveRecord::Migration
add_primary_key "ways", ["id", "version"]
add_index "ways", ["id"], :name => "ways_id_version_idx"
change_column "ways", "version", :bigint, :limit => 20, :null => false, :options => "AUTO_INCREMENT"
change_column "ways", "version", :bigint_auto_20
end
def self.down

View file

@ -65,7 +65,7 @@ class AddRelations < ActiveRecord::Migration
add_primary_key "relations", ["id", "version"]
add_index "relations", ["timestamp"], :name => "relations_timestamp_idx"
change_column "relations", "version", :bigint, :limit => 20, :null => false, :options => "AUTO_INCREMENT"
change_column "relations", "version", :bigint_auto_20
end

View file

@ -47,6 +47,8 @@ module ActiveRecord
types[:bigint_pk] = { :name => "bigint(20) DEFAULT NULL auto_increment PRIMARY KEY" }
types[:bigint_pk_64] = { :name => "bigint(64) DEFAULT NULL auto_increment PRIMARY KEY" }
types[:bigint_auto_64] = { :name => "bigint(64) DEFAULT NULL auto_increment" }
types[:bigint_auto_11] = { :name => "bigint(11) DEFAULT NULL auto_increment" }
types[:bigint_auto_20] = { :name => "bigint(20) DEFAULT NULL auto_increment" }
types
end