Category "entity-framework"

Meta description is not showing on google results page - REACTJS

my meta description tag is not showing on google result page as well as favicon. my technology stack consist of - reactjs on frontend & entity framework on

Fetching data in level 3 of self-referencing / parent-child relationship

I am programming a multilevel menu / submenu in ASP.NET MVC. I have this table: Id Name ParentId ---------------------------------- 1

What is an alternative to using MutablePropertyExtensions.SetValueComparer

I recently upgraded to .Net 6 and it's seems that Microsoft has removed Microsoft.EntityFrameworkCore.MutablePropertyExtensions.SetValueComparer although nothin

Creating tables in SQL with the corresponding attributes, from an ER model

If I have an ERD: https://i.stack..com/gj3Sn.png Which I'm trying to type up in postgres SQL. How could this be done? So far i've got:

Prevent EF from creating table from subclasses

I have 2 classes; Product and Book. Book is subclass of Product. In my DbContext there is only DbSet of Product. I'm using EF Code-First approach. when EF creat

EF6 Entity framework sometimes slow query on SQL Server

We have started a new project in .NET Core. We are just starting out and we are hitting a Web API endpoint to get some reference data of 8 records. We noticed

MissingMethodException when migrating from Ef 6.2 to 6.4.4

For a .net framework 4.8 project, when I update the EF reference from 6.2 to 6.4.4 the application throw an error System.MissingMethodException: Unable find 'V

EntityFramework 5 Logging in Azure Functions

TLDR; How can we make EF5 logging into its own category instead of the category of the Azure Function? After we upgraded our Azure Functions from .NET core to .

EF core Invalid column name after reverse engineering database using EF Power Tools

I have an API using ASP.NET Core 6 & EF6 and I reverse engineered my database (SQL Server) using the EF Core Powers Tool extension. When I try to insert a P

The corresponding CLR type for entity type cannot be instantiated Table-per-type

Using EFCore 5 I've been trying to follow Microsoft tutorials to create a field in a model class that may reference two other classes. In my case, I have an abs

Relationships in Entity Framework with users from AzureAD

I'm relatively new to Microsoft solutions and I need your guidance. I'm quite certain the answer exist somewhere, but I lack key words for my searches. My stack

COULD NOT LOAD TYPE 'System.Security.Principal.WindowsImpersonationContext' from assembly 'mscorlib'

I'm creating an ASP.NET API Core application, to handle API services, which communicate to an Oracle Database. At runtime, when the process tries to connect to

Entity Framework Core - Relationship between owned child and another chained owned child

I am stuck with Problem, that I am trying to solve the right way. I have multiple one-to-many 'owning' relationships. But I have a duplicate relationship betwee

Errors when "Update model from database" VS2022 and EF5

I am trying to sync EF5 w/ the database by: stackoverflow.com/questions/9708189/… Issue is that after I choose "Updates model from Database" there are er

ASP.NET MVC / Entity Framework - Controller generation is somehow using old properties

After adding and altering columns in the SQL database, I've refreshed the Entity Model (Entity Framework 6) and deleted all controllers and views, to generate t

Linq Nullable object must have a value. errors in .NET 6 and EF Core

I have this code: IQueryable<WinnerClassExtend> dataList = from Class in _context.AllClass join Winner in _context.AllWinners on Class.ClassId equals Win

Object reference not set to an instance of an object on c# EF6

Sometime I get this error message when i run my project in Hosting.There is no problem on the local server. Sometimes this error comes up on the server, sometim

Entity Framework 6 unable to update related models

I have list of models that are attached to a product model, insert is working, but when updated Entity is only updating the product model and ignoring the relat

"The instance of entity type cannot be tracked" error when adding detached entity tree

I am unable to add the Deal entity because Buyer and Seller are referencing the same city "City1". I work with detached entities here because I receive the whol

NET 5 and EF: how to use AddPooledDbContextFactory in liu of DbContext in services

I recently came across AddPooledDbContextFactory concept as part of my NET 5 self-education piece and am keen to implement it properly. However, I am not sure h