From c1132f7093b29e6acb95be4d262a07d5b04082d3 Mon Sep 17 00:00:00 2001 From: Vijay Dev Date: Tue, 26 Apr 2011 23:40:47 +0530 Subject: added the list of reversible commands in the newer migrations --- railties/guides/source/migrations.textile | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'railties/guides') diff --git a/railties/guides/source/migrations.textile b/railties/guides/source/migrations.textile index 18ae8a2251..27f8a9303e 100644 --- a/railties/guides/source/migrations.textile +++ b/railties/guides/source/migrations.textile @@ -342,10 +342,14 @@ h4. Writing Your +change+ Method The +change+ method removes the need to write both +up+ and +down+ methods in those cases that Rails know how to revert the changes automatically. Currently, the +change+ method supports only these migration definitions: -* +create_table+ * +add_column+ -* +rename_column+ * +add_index+ +* +add_timestamp+ +* +create_table+ +* +remove_timestamps+ +* +rename_column+ +* +rename_index+ +* +rename_table+ If you're going to use other methods, you'll have to write the +up+ and +down+ methods normally. -- cgit v1.2.3