MSSQL connection string
Posted: Thu Apr 11, 2024 11:29 am
I am using c# and Blazor along with MSSQL. My SqlConnection in application looks like this:
Data Source=MYPC\\SQLEXPRESS;Connection Timeout=30;Command Timeout=30;Persist Security Info=False;TrustServerCertificate=True;Integrated Security=True;Initial Catalog=MYDB"
If I leave it like this it will not connect through the designer to my database but if I delete from that string one backslash than it works with no problem.
My problem is that I am not able to remove one backslash from the connection string which I am sending to report before printing my report and my report appears blank from the same database with what I developed and preview shows data from the database. No error, no nothing. So I need to know if there is a connection string problem. I tried to put a connection string on my report to see what I have during report execution but I am not able to do that.
Please give me some advice on how to debut my report.
Data Source=MYPC\\SQLEXPRESS;Connection Timeout=30;Command Timeout=30;Persist Security Info=False;TrustServerCertificate=True;Integrated Security=True;Initial Catalog=MYDB"
If I leave it like this it will not connect through the designer to my database but if I delete from that string one backslash than it works with no problem.
My problem is that I am not able to remove one backslash from the connection string which I am sending to report before printing my report and my report appears blank from the same database with what I developed and preview shows data from the database. No error, no nothing. So I need to know if there is a connection string problem. I tried to put a connection string on my report to see what I have during report execution but I am not able to do that.
Please give me some advice on how to debut my report.