Which method in the DbContext class is typically overridden to configure model entities and relationships?

  • OnModelCreating
  • OnConfiguring
  • OnEntityConfiguring
  • ConfigureModel
To configure model entities and relationships in Entity Framework Core, developers often override the "OnModelCreating" method in the DbContext class. This method allows for fluent API configuration and specifying entity relationships, indexes, and more.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *