Skip to main content
Filter by
Sorted by
Tagged with
1 vote
2 answers
237 views

I have a code snippet that uses let with a where clause. private List<string> Example2() { var query1 = from c in _context.Customers let custPurchases = _context.Purchases....
Romanov Nikita's user avatar
1 vote
1 answer
79 views

Using HotChocolate v15.1.8 with EF v9.0.7 and Mapster v7.4.0, I encounter a bug with [UseSorting] / [UseFiltering] LinQ conversions which appear invalid when applied to DDD ValueObject or EF complex ...
Rémi Lamotte's user avatar
2 votes
2 answers
65 views

I have two model classes; the first contains all the fields of the table which are not multilanguage fields. public partial class Brand { public long BrandID { get; set; } public string Name { ...
pitaridis's user avatar
  • 3,055
3 votes
3 answers
114 views

How to use EF Core to manage a composite foreign key referencing a parent record whose ID is generated by a database trigger after insertion? The parent entity's ID is not available during initial ...
Lance's user avatar
  • 403
-1 votes
1 answer
48 views

I'm new to ASP.NET Core 9 Web API, I'm trying to do a scaffold with a existing database and using user-secrets follow the Microsoft documentation. I created my user secret file and my keys something ...
Joanny's user avatar
  • 1
0 votes
2 answers
98 views

I have a new .NET 9 Razor page Blazor server-side project. I used EF Core Power Tools to import my database schema and generate the DbContext and model classes. I created a MetaData class for one of ...
StuartV's user avatar
  • 135
1 vote
1 answer
434 views

I am trying to configure multiple tenants in ASP.NET Core 8 MVC project. I am using Finbuckle.MultiTenant.AspNetCore - v9.0.0 Finbuckle.MultiTenant.EntityFrameworkCore - v9.0.0 Microsoft....
Roshan's user avatar
  • 3,406
0 votes
1 answer
54 views

In Entity framework I could build a where clause as a string. For example; var whereClause = "ID > 0 and !Inactive"; pList.AddRange(MyData.Set<T>().Where(whereClause).ReduceCasts()....
Lance's user avatar
  • 403
0 votes
1 answer
197 views

I am facing an issue where I cant fetch an entity when using .FirstOrDefaultAsync() with a GUID as the primary key. If I fetch all entries first and then run .FirstOrDefault it works. The entity in ...
rosi97's user avatar
  • 245
-1 votes
2 answers
562 views

I am using DDD architecture and the following code changes the aggregate root (basically adds a comment which is an entity to the aggregate root). public sealed class AddCommentToPostCommandHandlers : ...
arman's user avatar
  • 909
0 votes
1 answer
263 views

I am trying to follow DDD in a new project im working on and have run into an issue when it comes to configuring one of my ValueObjects. I have the following AggregateRoot public sealed class Event : ...
CoderK's user avatar
  • 109
0 votes
0 answers
43 views

I'm working with a MySQL table that has a composite unique constraint on two columns (column1 and column2), like this: CREATE TABLE example_table ( column1 INT, column2 INT, column3 ...
Saggy's user avatar
  • 85
4 votes
2 answers
4k views

I'm working on an ASP.NET Core project using Entity Framework Core and Npgsql for PostgreSQL. I'm trying to create a DbContext to manage my database, but I'm encountering the following error when I ...
Ziad Diyaa's user avatar