Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

huangapple go评论57阅读模式
英文:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate - Cannot connect to Azure SQL from Excel

问题

我正在尝试从Excel连接到Azure SQL服务器数据库。我已经使用了Microsoft帐户身份验证选项,通过Azure AD和MFA身份验证登录,但在最后一步时,我收到了以下错误消息。

加密支持

提供的服务器名称与SQL服务器SSL证书上的服务器名称不匹配。请联系您的管理员;请查看下面的链接获取更多信息。或者,您可以更改连接加密设置。您是否希望继续使用未加密的连接?

我知道错误的根本原因与将加密设置为是或启用等相关,理论上应该可以解决,但可编程更改连接字符串的地方似乎不存在。

这让我想,虽然AD连接无疑是将Excel连接到SQL服务器的最安全方式,但是否还有其他选项呢?

英文:

I am attempting to connect to an Azure SQL server database from Excel. I have used the Microsoft account authentication option, logged in via Azure AD and MFA authentication, at the last step I get the error message below.

Encryption support

> The server name provided doesn't match the server name on the SQL server SSL certificate. Please contact your administrator; to see the link below for more information. Alternatively, you could change your connection encryption settings. Would you like to continue using an unencrypted connection ?

I know the source of the error relates to setting the encryption to yes or enabled etc and it should work, however there is nowhere to programmatically change the connection string.

This is making me think, whilst AD connection is by far the most secure way to connect excel to SQL server, I wonder if there are any other options.

答案1

得分: 2

我尝试从Excel连接SQL Server,选择了SQL Server作为获取数据选项,输入了SQL Server名称并使用了AD多重因素身份验证,我收到了以下错误:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

我尝试按照以下步骤连接:

前往Excel -> 数据 -> 其他数据源 -> 从OLEDB

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

点击构建:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

选择提供程序并点击下一步:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

输入SQL Server的名称,选择身份验证模式,输入AD UID,选择数据库:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

测试连接:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

点击确定,然后会弹出身份验证窗口,只输入用户名并点击连接:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

点击连接后,我收到了密码身份验证和身份验证选项:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

成功身份验证后,成功连接到数据库:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

英文:

I tried to connect SQL server from Excel I selected Sql server as get data option enter the sql server name and used AD MFA authentication I got the below error:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

I tried to connect by following below procedure:

Goto excel ->Data ->Other source -> From OLEDB

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

Click on build:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

Select the provider and click on next:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

Enter the name of SQL server Selected the Authentication mode, enter AD UID select the db:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

Tested the connection:

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

Click on OK, After that will get Authentication window Enter only the username and click on connect

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

After clicking on connect I got Password Authentication and authentication option

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

After successful authentication it connected successfully to the database.

Encryption support the server name provided doesnt match the server name on the SQL server SSL certificate – Cannot connect to Azure SQL from Excel

huangapple
  • 本文由 发表于 2023年3月3日 22:33:32
  • 转载请务必保留本文链接:https://go.coder-hub.com/75628370.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定