赞
踩
一、EF Core8 数据库连接字符串报错
A connection was successfully established with the server, but then an error occurred during
解决方案:
连接字符串增加标识
TrustServerCertificate=True
或者加(Encrypt=True;TrustServerCertificate=True;)即可:
"ConnectionStrings": {
"DefaultConnection": "Data Source=LAPTOP;Initial Catalog=DB;persist security info=True;User ID=sa;Pwd=XXXXX;Encrypt=True;TrustServerCertificate=True;"
},
字符串格式2:
"SqlServer": "data source=xxx;initial catalog=QL.Back.Template6;uid=xxx;pwd=xxxx;TrustServerCertificate=True;"
更多:
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。