I have a minimal api project that works with a single DBContext for one SqlServer db that is in a separate EFCore project. I've added a second GFContext to the EFCore project. When I attempt to access an entity in the new GFContext, the
protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
is never called and I get the: InvalidOperationException: No database provider has been configured ... error message.
The GFContext module includes:
public GFContext(DbContextOptions<GFContext> options) : base(options)
How do I get the 2nd Context to call the overrided OnConfiguring?
The only solutions I found are for asp.net and dbcontext factories.
Thanks ... Abbott