I am unable to scaffold an API Controller with CRUD using DBContext in Visual Studio 2019 ver 16.xx
When I select the option to add an API Controller. I get an error saying "There was an error running the selected Code Generator. Package restore failed. Rolling back changes for the project xxx" I have tried to add the Entity Framework…
Entityframework Core, combine to database fields into model value.
Using entity framework core, doing custom model building code first, I want to store a system.numerics Vector2 in SQL server. In the database I represent the value as two distinct fields, 'ValueX' & 'ValueY'. How can I configure the entity in EF such…
Related table data not saved on call to SaveChangesAsync
I have these entities in my C# application: public class Balance1 : IAnalyticsSection { public int Id { get; set; } public Guid DataFileId { get; set; } public string Side { get; set; } public decimal AverageHeadSway { get; set; } …
Entity framework code convert to sql
Hi, I have to convert my ef code to sql, but i have some problems to accomplish this task, What can be the best ways to retrieve a query from entity framework ? Thanks
Code First Migrations - Package Manager Console Host Version 5.9.1.0
Need your expertise. Please advise. There's old table which already released to Production. It's already migrated and had related 2 recorded on the list of migrations ~IRM.SIMSDB\Migrations. In recent, we want to make four changes on this table.…
Does package microsoft.entityframeworkcore.sqlserver work with xamarin.forms?
I am getting an error when trying to connect. I am only testing with the xamarin.ios project. I realize that connecting to a sql database over the internet is not a good idea. However, in my case the application connects only to a local database on a…
Order of SQL CRUD operations in Entity Framework Core
Many people have asked this question, but I am referring to something different. I have a table that stores facts. And this table contains the below columns. CREATE TABLE [dbo].[XTABLE] ( [identity] nvarchar(50) not null [seq] int not null…
How to configure Serverless Azure SQL for Multiple ASP.NET Core web sites with EF Core
I'm planning on hosting single instances of multiple (two for starters) ASP.NET/EF Core Web Sites in Azure Kubernetes and they need databases for persistence. These websites will be code first and not share any data structures. All of these sites will…
GPU based database provider for Entity Framework Core 5 and beyond.
For a wicked fast database, is there any plans for a Entity Framework Core 5 ~ 6 provider to any of the in memory GPU databases that are out or that are coming out? I have seen an example of Rapids Dask on a NVidia A6000 and it seems like a much better…
Setup failed when installing .NET Core SDK 3.1.407 and some others in Windows 10 Home | Error code: 0x80070659
Hi! I am trying to install .NET Core SDK 3.1.407, .NET SDK 5.0.201 and Microsoft Windows Desktop Runtime - 3.1.13 (x64) but the setup is always returning the same error code (0x80070659). I dont know what to do, im the owner of the device (i have…
Not able to reference Xamarin.Android to class library project with .net 5
Hi, I am receiving following error while adding reference to Class Library Project from android project a and ios project. Severity Code Description Project File Line Suppression State Error Project '..\DeliveriesApp\DeliveriesApp.csproj' targets…
AutoMigration : can't ALTER table or column name error
I have some issued in auto-migration approach which is given by M.S. Docs (link is below): https://zcusa.951200.xyz/en-us/ef/core/managing-schemas/migrations/applying?tabs=dotnet-core-cli ( My Code ) var host =…
Entity Framework Core 5.0 scaffold-dbcontext hangs within Package Manager
I have created my first scaffold-dbcontext command and run it in Package Manager Console in Visual Studio 16.6.2. After 'Build succeeded.' the PM just hangs. I can do nothing except restart Visual Studio to get PM back. When I re-open the project the…
How to do AutoMigration in Entityframework core without using command (Using Programming only)
I use EF core in My project and I want migrate my context using Programming (not command) So I use these two concpets one by one 1. using (var serviceScope = app.ApplicationServices.GetRequiredService<IServiceScopeFactory>().CreateScope()) { …
Entity Framework Core Tool doesn't work from dotnet tool
Hello ! I've encoutered an issue using EntityFrameworkCoreTool 5.0.4 : When I install the nuget package and run a scafold command from the package manager console, it works fine. But when I install it as a dotnet tool using dotnet tool install dotnet-ef…
About.core3.1 Dynamic Compiling
Hi, I was compiling some code dynamically with Core3.1 and was told that the platform didn't support it, but using the Framework was fine.I don't know how to return a responsibility, ask everybody to help using RRQMSocket; using RRQMSocket.RPC; …
Ef Core - weird behavior of AddRange
Here's my code: [Table("prom_term", Schema = "demo")] public class PromTerm { [Key] [Column("promotion_terminal_id")] [DatabaseGenerated(DatabaseGeneratedOption.Identity)] public int…
Why .NET Security Updates for x64 Windows Server includes many other packages including ones for Desktop systems and x86 systems
Hello, I'm curious how one is suppose to determine which of these packages in the update shown below is supposed to be installed when downloading from the MS Update Catalog? If you are running a Server OS (say 2016 Datacenter x64) and that server has…
SQL Server and EF Core, create “Lock Request Timeout” error
(I asked this on StackOverflow as well, figured I'd throw it out here too) I recently had my EF Core (2.1) code throw a DbUpdateException, caused by a lock request timeout. I think I understand the basic idea behind this (EF doesn't lock items until it…
EF Core add new record, assigned identity when life cycle is scoped
Hi In asp.net core 3.0 app with ef core 3.18, dbcontext registered AsScoped, when a new record created with identity set as integer and incremental, and automatic number identity value is assigned to that entity record, say 1, if at the same time in…