• Jobs
  • About Us
  • professionals
    • Home
    • Jobs
    • Courses and challenges
    • Questions
    • Teachers
  • business
    • Home
    • Post vacancy
    • Our process
    • Pricing
    • Assessments
    • Payroll
    • Blog
    • Sales
    • Salary Calculator

0

336
Views
Is it possible to remove an EF Core Database migration after the database is updated with the same

In .NET EF core, Is it possible to remove/revert a Database migration after the database is updated by "Update-database" command?

almost 3 years ago · Santiago Trujillo
1 answers
Answer question

0

Yes, it's possible, but only if it is the last migration or if you revert all migrations after it.

To revert all migrations including the desired, use the -Migration parameter of the same Update-Database command and pass the name/id of the migration before the desired (or special value 0 if it is the first)

Update-Database MigrationBeforeTheOneYouWantToRevert

For more info, see Applying Migrations - Command-line tools sections of the official EF Core documentation.

almost 3 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Our process Sales
Legal
Terms and conditions Privacy policy
© 2025 PeakU Inc. All Rights Reserved.

Andres GPT

Recommend me some offers
I have an error