To check out this repository please hg clone the following URL, or open the URL using EasyMercurial or your preferred Mercurial client.
root / db / migrate / 20100705164950_change_changes_path_length_limit.rb @ 442:753f1380d6bc
History | View | Annotate | Download (465 Bytes)
| 1 |
class ChangeChangesPathLengthLimit < ActiveRecord::Migration |
|---|---|
| 2 |
def self.up |
| 3 |
# these are two steps to please MySQL 5 on Win32
|
| 4 |
change_column :changes, :path, :text, :default => nil, :null => true |
| 5 |
change_column :changes, :path, :text, :null => false |
| 6 |
|
| 7 |
change_column :changes, :from_path, :text |
| 8 |
end
|
| 9 |
|
| 10 |
def self.down |
| 11 |
change_column :changes, :path, :string, :default => "", :null => false |
| 12 |
change_column :changes, :from_path, :string |
| 13 |
end
|
| 14 |
end
|