Rewrite migrations & restore schema