Rails -- Possible to run migration methods in generic rake task? -


I know this is not the best practice, and most likely should not be used as well, for migrations Is used, but I was wondering if it is possible to execute migration specific orders in regular RAK work. Something like this:

  Namespace: Working Dummy: Update = & gt; : Add Environment Addition: User, Deleted: Boolean, {: Zero = & gt; Wrong, default = & gt; Wrong} end of end  

thanks

it is possible to run your Arbitrary proxy-migration in rack works:

  Namespace: Working Dummy: Update = & gt; : Environmental ActiveRecord :: Base.connection.add_column: User, Deleted ,: Boolean,: Cord = & gt; Wrong, default = & gt;  

If you are doing a lot of this type, use a short-hand:

  Namespace: Working Dummy: Update = & gt ; : Environment do c = ActiveRecord :: Base.Connect c.add_column: User, deleted ,: Boolean,: Cord = & gt; Wrong, default = & gt; Incorrect end and  

Comments

Popular posts from this blog

paypal - How to know the URL referrer in PHP? -

oauth - Facebook OAuth2 Logout does not remove fb_ cookie -

wpf - Line breaks and indenting for the XAML of a saved FlowDocument? -