696 questions with Entity Framework Core tags

Sort by: Updated
2 answers One of the answers was accepted by the question author.

Add Identity endpoints in my API

Hey I would like to add the identity endpoints in my API I add this service in program "builder.Services.AddIdentityApiEndpoints<IdentityUser>() .AddEntityFrameworkStores<ApplicationDbContext>();" but…

Microsoft Identity Manager
Microsoft Identity Manager
A family of Microsoft products that manage a user's digital identity using identity synchronization, certificate management, and user provisioning.
617 questions
Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,199 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,292 questions
asked 2024-01-21T15:19:13.9033333+00:00
Marnelle M'BENGUET 20 Reputation points
accepted 2024-01-24T07:26:54.9766667+00:00
Marnelle M'BENGUET 20 Reputation points
1 answer One of the answers was accepted by the question author.

Assign user to role during Registration

Hi Friends !!! I was wondering when a user Registers to my website can I assign them to a default role with the minimal privileges until I choose to add them to another role? Just wondering does the Startup.cs have some sort of Configuration that handles…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,199 questions
asked 2021-11-11T04:06:30.917+00:00
Ronald Rex 1,666 Reputation points
commented 2024-01-23T18:15:27.0333333+00:00
Graham Irvine 0 Reputation points
0 answers

How to group monthly sales by currency in Blazor Server application?

Hello, I am working on a Blazor Server application and I want to get the monthly total sales. I need to group these sales by the currency (USD, EURO, TL) that they were sold. Here is the query I am currently using to group monthly sales, but I need to…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,292 questions
asked 2024-01-22T17:57:58.0733333+00:00
Cenk 956 Reputation points
commented 2024-01-23T09:23:41.1866667+00:00
Wenbin Geng 711 Reputation points Microsoft Vendor
2 answers One of the answers was accepted by the question author.

How to connect SQL server instance (Always on) with EF6.4 (.NET framework 4.8 Application in C#)

I am using Entity framework 6.4 (C# application) to connect SQL server database(always on) via availability group listener. I found that my application will throw exception when SQL server proceed failover from primary SQL instant to secondary instant.…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
.NET
.NET
Microsoft Technologies based on the .NET software framework.
3,401 questions
SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
12,776 questions
asked 2024-01-12T05:58:16.49+00:00
Leo Ng 20 Reputation points
commented 2024-01-23T08:57:33.8066667+00:00
Leo Ng 20 Reputation points
1 answer

Scoped Life Time in .Net core

I added DBContext as scoped to project services When I use Promise.all to send requests from the frontend to send two requests at the same time, each request is processed separately and each one creates a new instance of the service. This creates two new…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,199 questions
asked 2024-01-21T06:09:16.95+00:00
Sahar Ash 0 Reputation points
answered 2024-01-21T18:30:32.28+00:00
Bruce (SqlWork.com) 56,846 Reputation points
1 answer One of the answers was accepted by the question author.

How to fix error NU1608: Detected package version outside of dependency constraint: OpenFeature 1.3.1 requires System.Collections.Immutable (>= 1.7.1 && < 8.0.0) but version System.Collections.Immutable 8.0.0 was resolved.

I am getting below error - error NU1608: Detected package version outside of dependency constraint: OpenFeature 1.3.1 requires System.Collections.Immutable (>= 1.7.1 && < 8.0.0) but version System.Collections.Immutable 8.0.0 was…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
asked 2024-01-18T06:38:32.0666667+00:00
GAURAV SINGH KHANGAR 20 Reputation points
accepted 2024-01-19T08:13:12.7833333+00:00
GAURAV SINGH KHANGAR 20 Reputation points
1 answer

How to separate out Identity server in a separate library to manage authentication of a user for multiple API projects in the application?

Suppose a solution has multiple different API projects so instead of re-writing the Authentication and authorization with an Individual user account (Identity Server) approach can we create a single library containing Identity server logic and use this…

Microsoft Identity Manager
Microsoft Identity Manager
A family of Microsoft products that manage a user's digital identity using identity synchronization, certificate management, and user provisioning.
617 questions
Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,199 questions
asked 2024-01-18T10:56:07.5633333+00:00
Piyush Meshram 20 Reputation points
answered 2024-01-18T19:10:49.51+00:00
Bruce (SqlWork.com) 56,846 Reputation points
2 answers

How can I post multiple entries at once, when selecting multiple options from a Multi List Dropdown

Hi All, I have hit a bit of a snag with this. I have a form, which contains a multi select dropdown menu. I want to allow the user to select as many options from the drop down menu and upon pressing submit, each different item selected will be saved into…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
.NET
.NET
Microsoft Technologies based on the .NET software framework.
3,401 questions
ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,199 questions
asked 2024-01-10T14:48:48.12+00:00
John Rowan 1 Reputation point
commented 2024-01-18T08:40:02.48+00:00
Ping Ni-MSFT 2,250 Reputation points Microsoft Vendor
2 answers

How to get monthly order count by status in a Blazor Server application?

Hello, I am working on a Blazor Server application and need to find the number of monthly orders that are either completed or continue based on their status. I have a query that works for a specific year and status, but I need to refactor it to accept…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,292 questions
asked 2024-01-16T12:46:42.32+00:00
Cenk 956 Reputation points
edited an answer 2024-01-18T07:12:42.0266667+00:00
Wenbin Geng 711 Reputation points Microsoft Vendor
2 answers One of the answers was accepted by the question author.

How to use the required modifier in C# properties correctly?

public class State { public int StateId { get; set; } public required string StateName { get; set; } public required ICollection<District> Districts { get; set; } public static void CreateNewState() { State state =…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,292 questions
asked 2024-01-15T06:46:19.88+00:00
Goverdhan Jayaram 40 Reputation points
commented 2024-01-16T12:32:56.5833333+00:00
Goverdhan Jayaram 40 Reputation points
1 answer

Why do I get optional dependent using table sharing?

Hi all; I am getting the following warning: Microsoft.EntityFrameworkCore.Update: Warning: The entity of type 'Event.Description#RichText' is an optional dependent using table sharing. The entity does not have any property with a non-null value to…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
asked 2024-01-07T15:30:56.06+00:00
David Thielen 2,281 Reputation points
answered 2024-01-15T16:02:45.06+00:00
David Thielen 2,281 Reputation points
0 answers

How to set up a Composite Primary Key in a Dependent Entity using a Composite Primary Key from the Principal Entity in Entity Framework Core?

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
12,776 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,292 questions
asked 2024-01-12T13:45:12.8366667+00:00
Goverdhan Jayaram 40 Reputation points
edited a comment 2024-01-15T03:20:28.08+00:00
Wenbin Geng 711 Reputation points Microsoft Vendor
5 answers

How do I save a file to SQL Server using Razor forms?

I have built a web application that connects to a local SQL Server. I would like to use the web form to save a file in the database. I am experiencing an error related to the model types and provider types. When I use a byte array type for the…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,199 questions
SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
12,776 questions
asked 2023-12-18T22:13:08.65+00:00
Robert Brown 0 Reputation points
commented 2024-01-14T18:37:30.5766667+00:00
Iris236 0 Reputation points
1 answer One of the answers was accepted by the question author.

Where and how should the database connection statement be stored?

Hello I am developing a wpf project with c# EF. I am currently using the Sqlite database file connection by defining it in the Configuring method. I think it is not the right approach to keep such information in the code. Where would it be healthier to…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,678 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,292 questions
asked 2024-01-11T10:03:13.8766667+00:00
fatih uyanık 80 Reputation points
accepted 2024-01-12T12:31:00.8133333+00:00
fatih uyanık 80 Reputation points
1 answer

how to include multiple entity in efcore?

public class MyEntity{ public int Id{get;set;} public MyEntityA EA{get;set;} public MyEntityB EB{get;set;} } _context.MyEntitys.Include(x=>x.Ea); how to Include EB . and in MyEntitiA there may be 3 or more entities.

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
asked 2024-01-08T09:59:02.77+00:00
mc 3,701 Reputation points
commented 2024-01-09T11:49:39.89+00:00
AgaveJoe 26,141 Reputation points
1 answer

How to map IQueryable object with a large data to another IQueryable object

Hello, I am currently working on a Blazor Server project and I am trying to map two IQueryable objects with Automapper. However, I am encountering an error and not sure how to solve it. Here is the error that I am getting: 2024-01-07…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,292 questions
asked 2024-01-07T19:01:06.3466667+00:00
Cenk 956 Reputation points
edited an answer 2024-01-08T14:52:39.45+00:00
AgaveJoe 26,141 Reputation points
4 answers One of the answers was accepted by the question author.

How to use Scaffold-DbContext in .NET Core for Sqlite database

I'm using .NET Core Version 7 and I want to use EF Core to access a Sqlite (*.db3) database file. This file has a password and I want to add the database tables to the project through database first. The scaffold-dbcontext code is as follows, but it…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,292 questions
asked 2023-09-04T12:42:06.4733333+00:00
Mohammad Hasan Salmanian 45 Reputation points
answered 2024-01-08T14:16:37.7+00:00
Antony Avril 0 Reputation points
0 answers

Microsoft.EntityFrameworkCore

Hello, I am using Microsoft.EntityFrameworkCore And SQLServer2022, but I have a problem. I added DBContext to my service as scoped, but I get this error. "The connection is already in a transaction and cannot participate in another…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
asked 2024-01-06T05:51:16.1433333+00:00
Sahar Ash 0 Reputation points
commented 2024-01-07T22:53:30.9266667+00:00
1 answer One of the answers was accepted by the question author.

"Need help with serving/streaming video files to frontend using Entity Framework, ASP.NET Core API (.NET 6) deployed on Azure App Services, and MongoDB deployed to Atlas"

Hi, I'm working on a project for streaming videos and I'm currently stuck on trying to figure out how do I serve / stream a video file for front end? If I run everything locally, the video stream is still sent from the backend to the frontend in chunk…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
6,931 questions
asked 2023-12-19T17:36:26.2666667+00:00
Max 20 Reputation points
accepted 2024-01-06T17:27:41.1566667+00:00
Max 20 Reputation points
3 answers One of the answers was accepted by the question author.

How to Auto Compute Date Time field in SQL server

I am trying to configure a field in model which is to be modified with insert and update. I tried multiple things but still could find the correct configuration for my requirement. Example : public class Author { public DateTime UpdatedAt { get; set;…

Entity Framework Core
Entity Framework Core
A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
696 questions
.NET
.NET
Microsoft Technologies based on the .NET software framework.
3,401 questions
ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,199 questions
SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
12,776 questions
asked 2024-01-03T14:43:43.6533333+00:00
net 6 newbie 121 Reputation points
accepted 2024-01-04T10:38:14.47+00:00
net 6 newbie 121 Reputation points