Showing posts with the label c#

[FIXED] How do I prevent malicious SQL injection attacks while allowing benign SQL injection?

Issue I'm writing an ASP.NET MVC4 application which ultimately builds a SQL SELECT statement dy…

[FIXED] How to run DDL commands on SQL Server database from C# and know about its results?

Issue I'm trying to create a database tool (linux, docker, c#, sql server). I use a Database.j…

[FIXED] Value too big for long and bigint in C# and SQL Server

Issue Our entire application has been using a long to store large number values. Like so: public …

[FIXED] Writing Recursive CTE using Entity Framework Fluent syntax or Inline syntax

Issue I am new to this recursion in both SQL and Entity Framework (ADO.NET Entity Mapping). I am w…

[FIXED] What Happens To a Query If It Times Out?

Issue Let's say I have a query that is sent to my SQL-Server database, it takes more than 30 se…

[FIXED] C# Oracle connection issue while using tasks and blocking collection

Issue I have some tasks (nWorkers = 3): var taskFactory = new TaskFactory(cancellationTokenSource…

[FIXED] Escaped interpolated strings in C#

Issue I find it unnecessarily cumbersome to create prepared statements in C# generally what you do …

[FIXED] C# Linq to SQL is contains safe for sql injections

Issue Generally I know that Linq to SQL is safe for SQL Injections because it is using SqlParameter…

[FIXED] Extra Quotation Mark in SQL Query

Issue I'm studying SQL injection and I got following example on this website: noreferrer"…

[FIXED] What happens to a parameterized query at database level

Issue I am working on few SQL injection bugs flagged by one of vulnerability scanner and was lookin…

[FIXED] SQLInjection with Npgsql/Postgres

Issue I want to learn how SQLInjection is working with the PostgresqlDb. I am using the Npgsql in C…

[FIXED] SQL DDL code to avoid SQL Injection Attacks

Issue The following piece of code is being highlighted as a security vulnerability to SQL injection…

[FIXED] NHibernate - Working with dynamic created Table

Issue I use Fluent NHibernate for project. Some database table created with SQL query dynamically. …

[FIXED] How can I write a SQL update query with a where clause using Entity Framework .NET Core

Issue I only want to update a field based on the condition that is mentionned below. I know how to …

[FIXED] Query with join, group by and count to linq

Issue im doing this query on sql and it works, but how do i make it to Linq ? select b.Name,a.ide…

[FIXED] MAUI 'SQLite Error 1: 'no such table: Players'.'

Issue when i want to add fields in the database it tells me "SQLite Error 1: 'no such tabl…

[FIXED] Angular web api routing

Issue I'm working on a angular web project where I have a angular site which communicates with …

[FIXED] Microsoft.Data.SQLite: Library e_sqlite3 not found

Issue Problem: I'm trying to develop an ASP.NET MVC (.Net Framework 4.7.2) web app in which I…

[FIXED] Converting MySqlDataReader records to ObservableCollection<T>

Issue I am trying to convert records from MySqlDataReader to ObservableCollection<T> but I …

[FIXED] ASP.NET Core. System.Data.SqlClient.SqlException - SSL_ERROR_SSL

Issue My specs: PC with MS SQL Server 2008 (SP4) - 10.0.6535.0; PC on Linux (Debian GNU/Linux) wit…