Our products support EF Code-First Migrations.
You can follow, for an example, this tutorial for the generation of migrations:
http://blogs.msdn.com/b/adonet/archive/ ... rough.aspx
Be aware that some additional settings should be implemented:
1. Add references to the Devart.Data.Oracle.Entity.dll and Devart.Data.Oracle.Entity.Migrations.dll assemblies to your project (these assemblies' names are for dotConnect for Oracle; other dotConnect providers include corresponding Devart.Data.Xxx.Entity.dll and Devart.Data.Xxx.Entity.Migrations.dll).
2. At first it is necessary to register SQL Generator in the constructor of the Configuration class which is a descendant of DbMigrationsConfiguration (it can be added to the user's project using the Enable-Migrations command in Package Manager Console):
Code: Select all
SetSqlGenerator(OracleConnectionInfo.InvariantName, new OracleEntityMigrationSqlGenerator());
The same for other dotConnect providers:
Code: Select all
SetSqlGenerator(MySqlConnectionInfo.InvariantName, new MySqlEntityMigrationSqlGenerator());
SetSqlGenerator(PgSqlConnectionInfo.InvariantName, new PgSqlEntityMigrationSqlGenerator());
SetSqlGenerator(SQLiteConnectionInfo.InvariantName, new SQLiteEntityMigrationSqlGenerator());
If you are working with dotConnect for Oracle, you should configure EF-provider for EF Code-First Migrations additionally (for example, it can be done in the constructor of your class-descendant of DbContext):
Code: Select all
var config = Devart.Data.Oracle.Entity.Configuration.OracleEntityProviderConfig.Instance;
config.Workarounds.IgnoreSchemaName = true;
config.Workarounds.ColumnTypeCasingConventionCompatibility = true;
If you are working with dotConnect for MySQL (or PostgreSQL or SQLite), it is enough to turn on only IgnoreSchemaName:
Code: Select all
var config = Devart.Data.MySql.Entity.Configuration.MySqlEntityProviderConfig.Instance;
config.Workarounds.IgnoreSchemaName = true;