Unable To connect to Database from visual studio 2022 ide for debugging

Sushil Agarwal 406 Reputation points
2024-07-08T17:32:58.74+00:00

Hello experts,

i am trying to connect to local pc sql server from visual studion 2022 community ide

its failing to establish connection by giving erro

connection was established scuusesfully but loin error occured SSL provide, error:0 the certificate chain issued by an authorty that is not untrusted

how to resolve this

Developer technologies | Visual Studio | Other
SQL Server | Other
0 comments No comments
{count} votes

Accepted answer
  1. ZoeHui-MSFT 41,496 Reputation points
    2024-07-09T01:43:56.3266667+00:00

    Hi @Sushil Agarwal,

    Try adding TrustServerCertificate=True; or adding Encrypt=False to your connection string.

    Regards,

    Zoe Hui


    If the answer is helpful, please click "Accept Answer" and upvote it.

    1 person found this answer helpful.
    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Olaf Helper 47,516 Reputation points
    2024-07-08T18:34:07.52+00:00

    SSL provide,

    Add "Encrypt=False" to your connection string to surpress connection SSL encryption.

    1 person found this answer helpful.
    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.