Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • zs123 11 posts 102 karma points
    Feb 18, 2020 @ 10:56
    zs123
    0

    When is Down() method in migrations executed?

    Hi community.

    I'm using migrations to update some property types. So, when an exception occurs in Up() method, it seems to me that Down() should be executed, right? But it's not happening. In neither of my migrations, Down() is never executed.

    I'm interested in an explanation of how it's working and how can I ensure that if something goes wrong in Up() I can revert actions with some logic in Down()?

    I tought that the downgrade will be auto performed if upgrade is not executed successfully.

Please Sign in or register to post replies

Write your reply to:

Draft