def self.up
create_table "acls", myisam_table do |t|
t.column "id", :integer_pk, :null => false
- t.column "address", :integer, :null => false
- t.column "netmask", :integer, :null => false
+ t.column "address", :inet, :null => false
+ t.column "netmask", :inet, :null => false
t.column "k", :string, :null => false
t.column "v", :string
end
add_index "acls", ["k"], :name => "acls_k_idx"
-
- change_column "acls", "address", :integer, :null => false, :unsigned => true
- change_column "acls", "netmask", :integer, :null => false, :unsigned => true
end
def self.down
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[:four_byte_unsigned] = { :name=> "integer unsigned NOT NULL" }
+ types[:four_byte_unsigned] = { :name=> "integer unsigned" }
+ types[:inet] = { :name=> "integer unsigned" }
types
end
types[:bigint_auto_11] = { :name => "bigint" } #fixme: need autoincrement?
types[:bigint_auto_20] = { :name => "bigint" } #fixme: need autoincrement?
types[:four_byte_unsigned] = { :name => "bigint" } # meh
+ types[:inet] = { :name=> "inet" }
types
end