tagged [entity-framework]
What to use instead DbEntityValidationException in EF Core?
What to use instead DbEntityValidationException in EF Core? With EF I used DbEntityValidationException catch branch (along with others) Now using .NET Core 3.17 with EF Core 3.17 and apparently there ...
- Modified
- 8 Sep at 11:56
How to apply migrations from code (EF Core)
How to apply migrations from code (EF Core) Here is some working EF6 migration code: What is the equivalent using EF Core?
- Modified
- 11 Nov at 20:45
Why Entity Framework have AddAsync?
Why Entity Framework have AddAsync? I understand why EF have `ToListAsync` or `SaveChangesAsync` - because it waits for db operation execution. But `AddAsync` just returns `Task.FromResult` - so why i...
- Modified
- 31 Oct at 11:21
EF code-first PluralizingTableNameConvention for ONE DbSet
EF code-first PluralizingTableNameConvention for ONE DbSet How do I toggle this convention `PluralizingTableNameConvention` for only a single table/DbSet? As far as I can tell, I can only do this to a...
- Modified
- 22 Nov at 06:51
How to set foreign key in EntityTypeConfiguration Class
How to set foreign key in EntityTypeConfiguration Class I just started to make EntityTypeConfiguration class and did following and in EntityTypeConfiguration cl
- Modified
- 21 Jan at 07:18
Multi-Context InMemory Database
Multi-Context InMemory Database Is it possible to have an InMemory database (ASP.NET Core) that is shared across multiple DbContexts? It seems that each DbContext type keeps its own database, even whe...
- Modified
- 25 Jan at 07:18
Entity Data Model Wizard Too Slow (SQL Database)
Entity Data Model Wizard Too Slow (SQL Database) Using: visual studio 2012 Ultimate, ADO Entity Framework 6, Database: Sql express 2014 (installed on local PC), Database tables count: 174 table. I am ...
- Modified
- 6 May at 11:25
How to run Seed() method of Configuration class of migrations
How to run Seed() method of Configuration class of migrations I have 2 questions: 1) How can I run Seed() method from the package-manager console without updating-database model? 2) Is there a way how...
- Modified
- 22 May at 08:20
Unable to generate an explicit migration in entity framework
Unable to generate an explicit migration in entity framework I am adding a new migration but this message shows: > Unable to generate an explicit migration because the following explicit migrations a...
- Modified
- 7 Feb at 03:9
Concurrency exceptions in Entity Framework
Concurrency exceptions in Entity Framework When calling `SaveChanges` / `SaveChangesAsync` in Entity Framework (CF, C#), if a change conflict occurs (for example, the values has been updated since las...
- Modified
- 26 Feb at 08:36