Category "entity-framework-6"

EF6 allow read but disable insert/update/delete during transaction

I am doing some "sync" between different platform. During this sync I try to add/update/remove records. For it I'm wrapping all functionality in TransactionScop

How to GroupBy week in Entity Framework in PostgreSQL

I have a table which has column DateTime. And I want to group this by week. There are no problem to group by date or by month. But how to group by week? I need

Use JSON_ARRAYAGG with Entity Framework Core

I am trying to use JSON_ARRAYAGG(JSON_OBJECT(...)) in Entity Framework Core but I don't know much how to trick Entity Framework Core to use this function with a

Linq .Distinct() add extraneous ordering

My entity has a computable geography::point column (represented by DbGeography type in code) When I call a .Distinct() method on query for this entity it adds O

CreateDbCommandDefinition in the custom DbProviderServices not called?

I need to intercept the call to the following method of DbProviderServices: DbCommandDefinition CreateDbCommandDefinition(DbProviderManifest providerManifest, D

EF6:Parent context null inside same child query

My database contains below table in parent child relationships:- Gender->Audit->Request(All are in 1:N Relationships) I want to fetch all Genders with cor

Trouble publishing ASP.NET project with Code First database to Azure - Permission

I cannot migrate my Code First database to Azure - Error hints at permission, but I can't figure out what's missing? I have created an empty SQL-database in Azu

Trouble publishing ASP.NET project with Code First database to Azure - Permission

I cannot migrate my Code First database to Azure - Error hints at permission, but I can't figure out what's missing? I have created an empty SQL-database in Azu

Getting the result of a computed column from database into an entity

In a project using Entity Framework, say I have an entity such as [Table("MyTable")] public partial class MyTable { public string FirstName { get; set; }

The type 'Company.Model.User' and the type 'Company.Core.Model.User' both have the same simple name of 'User' and so cannot be used in the same model

I have a base entity class MyCompany.Core.Model.User which is to be used for common properties of a User entity: public class User { public string Username