Why I can't get Entity Framework Migration to initial state?

entity-framework, entity-framework-5, entity-framework-migrations

Solution

Here's a answer. Please recover migration folder and its migrations file (recover to your project). Then follow steps from my theard http://pawel.sawicz.eu/entity-framework-reseting-migrations/

1) Update-Database -Targetmigration:0 - it's the key! first 2) Wipe out tables/migrations (you dont have to delete whole folder) 3) Add-Migration Initialise 4) Update-Database

Problem

I have deleted development database, and Migrations folder from project. When running unit test with use my project development database is recreated. I don't understand why running update-database gives me ``` PM> Update-Database Specify the '-Verbose' flag to view the SQL statements being applied to the target database. Applying code-based migrations: [201302201840012_wieleDoWielu]. Applying code-based migration: 201302201840012_wieleDoWielu. ``` Why migration: 201302201840012_wieleDoWielu is remembered ? How Can I delete it? Where is stored? Best Regards Przemysław Staniszewski

Original source