ASP.NET Core 7.0 API Error

thanhsang Thach 1 Reputation point
2022-12-03T08:34:50.99+00:00

public class DataDepartment
{
public string? Dept_ID { get; set; }
public string? Dept_Name { get; set; }
public DateTime Modify_Date { get; set; }
public bool? Hide { get; set; }
}

Connection String:
"DBSettingConnection": "Data Source=####;Initial Catalog=####;User Id=####;Password=####;Integrated Security=True;Encrypt=False;ApplicationIntent=ReadWrite;MultiSubnetFailover=False"

When execute: Error: Internal Server Error

266745-response-1670055658700.txt

And try setting TreatTinyAsBoolean=false in connection string
Error:
266833-response-1670055525026.txt

Developer technologies C#
{count} votes

1 answer

Sort by: Most helpful
  1. thanhsang Thach 1 Reputation point
    2022-12-15T13:52:10.397+00:00

    Tks your feedback.
    In database has somes row is not null[Null] it's ''
    I updated it's to null[Null] and it's work ok.

    Tks.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.