Skip to Content
0

HANA JDBC Connection Refused

Jul 13, 2017 at 04:14 PM

904

avatar image

Hi all,

I know this question had been already asked but I cannot figure out a solution.

When trying to connect Hana Express Edition Studio with Eclipse (as in the SAP tutorial https://www.sap.com/developer/how-tos/2016/09/hxe-howto-eclipse.html), I get the following error:

Exception Stack trace:

com.sap.ndb.studio.jdbc.JDBCConnectionStatus: Database connection is not available; see error log at com.sap.ndb.studio.jdbc.JDBCPlugin.createConnection(JDBCPlugin.java:281) at com.sap.ndb.studio.navigator.wizards.newsapsystem.NewSAPSystemWizard$1$1.call(NewSAPSystemWizard.java:308) at com.sap.ndb.studio.navigator.wizards.newsapsystem.NewSAPSystemWizard$1$1.call(NewSAPSystemWizard.java:1) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source)

Caused by: com.sap.db.jdbc.exceptions.JDBCDriverException: SAP DBTech JDBC: Cannot connect to jdbc:sap://192.168.10.23 [Cannot connect to host 192.168.10.23:30013 [Connection refused: connect], -813.]. at com.sap.db.jdbc.exceptions.SQLExceptionSapDB._createException(SQLExceptionSapDB.java:126) at com.sap.db.jdbc.exceptions.SQLExceptionSapDB._createException(SQLExceptionSapDB.java:221) at com.sap.db.jdbc.exceptions.SQLExceptionSapDB.generateDatabaseException(SQLExceptionSapDB.java:57) at com.sap.db.jdbc.Driver._connect(Driver.java:821) at com.sap.db.jdbc.Driver.connect(Driver.java:159) at com.sap.ndb.studio.jdbc.JDBCConnection$1.run(JDBCConnection.java:169)

Session data:

eclipse.buildId=4.6.3.M20170301-0400

java.version=1.8.0_131

java.vendor=Oracle Corporation

BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=en_US Framework arguments: -product org.eclipse.epp.package.java.product -product org.eclipse.epp.package.java.product Command-line arguments: -os win32 -ws win32 -arch x86_64 -product org.eclipse.epp.package.java.product -data file:/C:/Users/Carlo/workspace/ -product org.eclipse.epp.package.java.product

What should I do?

Thanks in advance,

Carlo

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Carl Soane
Jul 18, 2017 at 10:36 PM
1

Hello Carlo:

The default instance number for HANA Express databases is 90. The HANA DB port used by HANA Studio is 3<instance number>13, meaning that it should by default by 39015. It looks like you are trying to connect to 30013 per the following excerpt from your error message:

"Caused by: com.sap.db.jdbc.exceptions.JDBCDriverException: SAP DBTech JDBC: Cannot connect to jdbc:sap://192.168.10.23 [Cannot connect to host 192.168.10.23:30013 [Connection refused: connect], -813.]. at"

Try changing your port to 39013.

Regards,

Carl

Share
10 |10000 characters needed characters left characters exceeded