I am using .net core entity framework.
I have multi tenant dbs. so I have kept one root tenant db as base. and I want to replicate those schema changes to all other dbs using entity framework. I am generating my models using following command.
Scaffold-DbContext "Data Source=(local);Initial Catalog=sampleTenantDb;Integrated Security=True" Microsoft.EntityFrameworkCore.SqlServer -OutputDir Tenants -Force
So when creating new tenant, I simply use
context.Database.EnsureCreated();
But when I add new table in code, I want to apply it to all tenants. So how do I do it?
I tried following but, it doesn't work (not adding remanining tables)
myDbContext.Database.Migrate();