Omar Al Jaber
Omar Al Jaber

Reputation: 39

Migration Error in Entity Framework with Oracle Database

I am using Code First, and I want to migrate it to ORACLE database, after multiple migrations process, I am getting this error,

The best overloaded method match for Oracle.ManagedDataAccess.EntityFramework.OracleMigrationSqlGenerator.Generate(System.Data.Entity.Migrations.Model.CreateTableOperation) has some invalid arguments

Upvotes: 1

Views: 2486

Answers (2)

mrduab
mrduab

Reputation: 11

I'm facing the same problem finally I solve it by opening the database and delete the migration_history table manually and run the command again. see at EF5 Code First - Changing A Column Type With Migrations

Upvotes: 1

Omar Al Jaber
Omar Al Jaber

Reputation: 39

in each migration you will save a record in __MigrationHistory, so in case there is no sync between the code and the migration do the following:

  1. delete the migration history table in the database.
  2. migrate it again by create new migration 'in package manager console' add-migration data.

  3. update the migration to database update-database

Upvotes: 0

Related Questions