大屏幕链接MSSQL问题

Blade 未结 2 652
wafergalet
wafergalet 剑童 2022-07-25 10:18

一、该问题的重现步骤是什么?

2022-07-25 10:12:29.745 ERROR 26868 --- [eate-1836786457] com.alibaba.druid.pool.DruidDataSource   : create connection SQLException, url: jdbc:sqlserver://10.14.2.15:1433;DatabaseName=EDI, errorCode 0, state null


java.sql.SQLException: validateConnection false

at com.alibaba.druid.pool.DruidAbstractDataSource.validateConnection(DruidAbstractDataSource.java:1418)

at com.alibaba.druid.pool.DruidAbstractDataSource.createPhysicalConnection(DruidAbstractDataSource.java:1733)

at com.alibaba.druid.pool.DruidDataSource$CreateConnectionThread.run(DruidDataSource.java:2838)

Caused by: java.lang.NullPointerException: null

at com.microsoft.sqlserver.jdbc.SQLServerStatement.ensureSQLSyntax(SQLServerStatement.java:698)

at com.microsoft.sqlserver.jdbc.SQLServerStatement.doExecuteStatement(SQLServerStatement.java:724)

at com.microsoft.sqlserver.jdbc.SQLServerStatement$StmtExecCmd.doExecute(SQLServerStatement.java:685)

at com.microsoft.sqlserver.jdbc.TDSCommand.execute(IOBuffer.java:4026)

at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeCommand(SQLServerConnection.java:1416)

at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeCommand(SQLServerStatement.java:185)

at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeStatement(SQLServerStatement.java:160)

at com.microsoft.sqlserver.jdbc.SQLServerStatement.execute(SQLServerStatement.java:658)

at com.alibaba.druid.filter.FilterChainImpl.statement_execute(FilterChainImpl.java:3010)

at com.alibaba.druid.filter.FilterAdapter.statement_execute(FilterAdapter.java:2484)

at com.alibaba.druid.filter.FilterEventAdapter.statement_execute(FilterEventAdapter.java:188)

at com.alibaba.druid.filter.FilterChainImpl.statement_execute(FilterChainImpl.java:3008)

at com.alibaba.druid.filter.FilterAdapter.statement_execute(FilterAdapter.java:2484)

at com.alibaba.druid.filter.FilterEventAdapter.statement_execute(FilterEventAdapter.java:188)

at com.alibaba.druid.filter.FilterChainImpl.statement_execute(FilterChainImpl.java:3008)

at com.alibaba.druid.proxy.jdbc.StatementProxyImpl.execute(StatementProxyImpl.java:147)

at com.alibaba.druid.pool.vendor.MSSQLValidConnectionChecker.isValidConnection(MSSQLValidConnectionChecker.java:50)

at com.alibaba.druid.pool.DruidAbstractDataSource.validateConnection(DruidAbstractDataSource.java:1398)

... 2 common frames omitted


二、你期待的结果是什么?实际看到的又是什么?

数据源链接没有问题,但是SQL查询脚本执行的时候就报这个错误

三、你正在使用的是什么产品,什么版本?在什么操作系统上?


四、请提供详细的错误堆栈信息,这很重要。

2022-07-25 10:12:29.745 ERROR 26868 --- [eate-1836786457] com.alibaba.druid.pool.DruidDataSource   : create connection SQLException, url: jdbc:sqlserver://10.14.2.15:1433;DatabaseName=EDI, errorCode 0, state null


java.sql.SQLException: validateConnection false

at com.alibaba.druid.pool.DruidAbstractDataSource.validateConnection(DruidAbstractDataSource.java:1418)

at com.alibaba.druid.pool.DruidAbstractDataSource.createPhysicalConnection(DruidAbstractDataSource.java:1733)

at com.alibaba.druid.pool.DruidDataSource$CreateConnectionThread.run(DruidDataSource.java:2838)

Caused by: java.lang.NullPointerException: null

at com.microsoft.sqlserver.jdbc.SQLServerStatement.ensureSQLSyntax(SQLServerStatement.java:698)

at com.microsoft.sqlserver.jdbc.SQLServerStatement.doExecuteStatement(SQLServerStatement.java:724)

at com.microsoft.sqlserver.jdbc.SQLServerStatement$StmtExecCmd.doExecute(SQLServerStatement.java:685)

at com.microsoft.sqlserver.jdbc.TDSCommand.execute(IOBuffer.java:4026)

at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeCommand(SQLServerConnection.java:1416)

at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeCommand(SQLServerStatement.java:185)

at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeStatement(SQLServerStatement.java:160)

at com.microsoft.sqlserver.jdbc.SQLServerStatement.execute(SQLServerStatement.java:658)

at com.alibaba.druid.filter.FilterChainImpl.statement_execute(FilterChainImpl.java:3010)

at com.alibaba.druid.filter.FilterAdapter.statement_execute(FilterAdapter.java:2484)

at com.alibaba.druid.filter.FilterEventAdapter.statement_execute(FilterEventAdapter.java:188)

at com.alibaba.druid.filter.FilterChainImpl.statement_execute(FilterChainImpl.java:3008)

at com.alibaba.druid.filter.FilterAdapter.statement_execute(FilterAdapter.java:2484)

at com.alibaba.druid.filter.FilterEventAdapter.statement_execute(FilterEventAdapter.java:188)

at com.alibaba.druid.filter.FilterChainImpl.statement_execute(FilterChainImpl.java:3008)

at com.alibaba.druid.proxy.jdbc.StatementProxyImpl.execute(StatementProxyImpl.java:147)

at com.alibaba.druid.pool.vendor.MSSQLValidConnectionChecker.isValidConnection(MSSQLValidConnectionChecker.java:50)

at com.alibaba.druid.pool.DruidAbstractDataSource.validateConnection(DruidAbstractDataSource.java:1398)

... 2 common frames omitted

五、若有更多详细信息,请在下面提供。

2条回答
  • 连mysql,为什么日志显示驱动是sqlserver的。

    0 讨论(0)
  • 2022-07-25 14:51

    商业版答疑规则见:https://sns.bladex.cn/article-14990.html

    请将账号邮箱修改为下单购买授权的qq邮箱便可咨询商业版疑问

    修改完邮箱后请将此贴删除并重新发一贴


    0 讨论(0)
提交回复