Java 如何从Pentaho连接到MSSQL?

Java 如何从Pentaho连接到MSSQL?,java,sql-server,pentaho,pentaho-spoon,pentaho-data-integration,Java,Sql Server,Pentaho,Pentaho Spoon,Pentaho Data Integration,我正在尝试将Pentaho连接到本地MSSQL服务器。 我启动了Microsoft SQL Server Management Studio,收到此窗口的提示,然后单击“连接”: 我正在使用Java8更新261和Pentaho7.1。我已从以下链接下载了MSSQL JDBC驱动程序: 并将mssql-jdbc-8.4.1.jre8.jar放入pdi-ce-7.1.0.0-12\data integration\lib文件夹中。我还将文件mssql-jdbc\u auth-8.4.1.x64.

我正在尝试将Pentaho连接到本地MSSQL服务器。 我启动了Microsoft SQL Server Management Studio,收到此窗口的提示,然后单击“连接”:

我正在使用Java8更新261和Pentaho7.1。我已从以下链接下载了MSSQL JDBC驱动程序:

并将
mssql-jdbc-8.4.1.jre8.jar
放入
pdi-ce-7.1.0.0-12\data integration\lib
文件夹中。我还将文件
mssql-jdbc\u auth-8.4.1.x64.dll
压缩到
C:\Program Files\Java\jre1.8.0\u 261\bin

现在,当我通过Spoon.bat文件启动Pentaho并尝试添加MSSQL连接时,我会出现错误,而且我不知道应该在字段中输入什么:

主机名:? 数据库名称:(数据库名称为PROFICE) 实例名称:? 港口:1433 用户名:? 密码:

从图中你可以看到我输入的内容。我还选中了
Use Integrated Security
框。 我发现以下错误:

Error connecting to database: (using class com.microsoft.sqlserver.jdbc.SQLServerDriver)
The TCP/IP connection to the host DESKTOP-CS70NHL, port 1433 has failed. Error: "Socket operation on nonsocket: configureBlocking. Verify the connection properties. Make sure that an instance of SQL Server is running on the host and accepting TCP/IP connections at the port. Make sure that TCP connections to the port are not blocked by a firewall.".

您使用的是SQL Express edition,这可能有点奇怪。它可能只在本地主机上侦听(意味着网络上的其他计算机无法连接到它),也可能在高位端口上侦听(因此到tcp/1433的连接将无法连接)。尝试打开SQL Server(数字)配置管理器并检查服务器协议中的TCP/IP设置。如果您在此处进行任何更改,您需要重新启动SQL Server服务才能使其生效。@AlwaysLearning OMG OMG非常感谢您!!!问题是它使用的是动态端口号,所以我设置为fixed 1433,并且TCP/IP协议被禁用。请将“mssql-jdbc_auth-8.4.1.x64.dll”复制到您的PDI位置“…data_integration\libswt\win64”。