All Questions
Tagged with sql-server .net
6,530
questions
1
vote
0
answers
64
views
Is it possible to specify the order in which EXCEPT operations are executed in SQL Server using Entity Framework Core?
I'd like to execute the following operation in SQL Server using Entity Framework Core (8.0.10):
A EXCEPT (B EXCEPT C)
I'm trying to write this query:
a.Except(b.Except(c))
But EF Core always ...
0
votes
1
answer
50
views
Extract CSV data from SQL Server column
I am looking for some assistance with handling some badly formatted data. I know similar questions have been asked but I haven't found any answers that pertain to this specific use case. My data flow ...
-2
votes
0
answers
31
views
ASP.Core app does not connect to SQL server when I run it with docker
I have a MVC CRUD application and an SQL Server.
Now I'm trying to dockerize them both, put them on separate containers
First I launched the SQL server on Docker from PowerShell with command:
docker ...
0
votes
0
answers
56
views
One or more of the key or foreign key properties are shadow properties and the entity is not being tracked
I have the following entity class:
internal class ServicePackage {
[Key]
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
public int Id { get; set; }
[Required]
[ForeignKey(&...
1
vote
2
answers
107
views
Deadlock is occuring very frequently
I am getting frequent deadlock in my appliation because
The application has 50 to 60 screens
we used SQL views for list screens
we are using mainly only 2 tables which stores all the data and it has ...
0
votes
0
answers
38
views
Include additional row-metadata when querying EF Core entities
In a SQL Server database queried via EF Core 6, I have an entity type MyEntity like this:
class MyEntity
{
int Id { get; set; }
string Name { get; set; }
int ParentId { get; set; }
...
0
votes
0
answers
30
views
Defining the target database with Entity Framework migration script generation
Generating script with Entity Framework requires the script to be run on a specific database. In our setup, we want our database administrators to run the script, but at the same time we want to ...
0
votes
1
answer
45
views
What are acceptable values for the parameter "errorCode" of Dts.Events.FireError in SSIS..?
SSIS has the scripting objects Script Task and Script Component, which provide the intended .Net programming environment. Therein are various event methods for triggering error conditions & ...
1
vote
1
answer
68
views
Get list of tables
I recently migrated a solution from >NET Framework 4.8 to .NET 8.
Two blocks of code stopped working.
Public Function GetTableList(vsDBName As String) As Collection
Dim oSQLServer As Server
...
-2
votes
0
answers
42
views
Failed to load x64\SNI.dll since SNI.dll is not deployed as part of Azure CI/CD
There is a MVC Web App in .Net Framework 4.7.1 and it refers class library for service layer which target both net471;net6.0-windows. The Azure pipeline is used to deploy the onpremise web sever. it ...
3
votes
1
answer
91
views
Is SqlException.Number unique for SQL Server exceptions?
In Microsoft.Data.SqlClient/System.Data.SqlClient libraries, the Sql errors returned with the SqlException have a property called Number.
In many of StackOverflow questions and other discussions over ...
0
votes
1
answer
63
views
NServicebus SQL server performance issues
We have a problem where our NServicebus application can't handle all the messages in the SQL Server transport input queue.
The default SQL-query to select messages is:
WITH message AS (SELECT TOP(1) * ...
2
votes
0
answers
126
views
How to catch the SQL Server network-related errors in C# correctly?
I want to catch all network-related exceptions from SQL Server (connection lost, timeout, etc.) and show a warning dialog to the end user when SQL Server instance suddenly goes down.
The SqlException ...
0
votes
1
answer
70
views
DateTime NLog c#
I am trying to write to my database the date of now with NLog and I have this error:
SqlDateTime overflow. Must be between 1/1/1753 12:00:00 AM and 12/31/9999 11:59:59 PM.
I tried everything but ...
-1
votes
0
answers
51
views
Table Valued Parameter insertion in mssql with python pyodbc
I am trying to replicate a SQL Server table valued parameter data insertion from a C# .Net code. Existing code use uses a Dapper library to use this
Utils.ListToTable(data).AsTableValuedParameter(&...