Jefferson
Jefferson

Reputation: 69

FluentMigrator command returning No migration found

I created a new public class M203_InsertPercent that will just insert data into the database base on the SQL statement. When I run the Migrate.exe using the connection string and the assembly FluentMigrator.Console returns "No migration found". I look into the database in the version table and my class name is not in that table. Is there something I am missing?

Upvotes: 5

Views: 3655

Answers (2)

LETOURNEUR Léo
LETOURNEUR Léo

Reputation: 311

Make sure your migration class is public as well :

https://github.com/fluentmigrator/documentation/blob/master/articles/faq.md

Upvotes: 6

Martin D.
Martin D.

Reputation: 2110

Make sure your migration class is decorated with the Migration attribute.

[Migration(203)]
public class M203_InsertPercent : Migration
{
    ...
}

Upvotes: 5

Related Questions