Hello,
Will the following work and be supported in the future ?
1. Reverse engineer the model, use existing database - one of many instances with identical schema .
2. Modify the context like this:
publicpartialclassMyContext:DbContext{
private string connectionString;
public MyContext(string _connectionString) : base ()
{
connectionString = _connectionString;
}
protectedoverridevoidOnConfiguring(DbContextOptionsBuilderoptionsBuilder){optionsBuilder.UseSqlServer(connectionString);}
....
3. Create MyContexts locally (without DI) and use different connection strings for databases.
Thanks,
Bartek