Quantcast
Channel: SCN : All Content - SAP HANA Developer Center
Viewing all articles
Browse latest Browse all 6745

Call Stored Procedure from JAVA

$
0
0

Hi all,

 

I have a StoredProcedure on my HANA db and I am trying to call it from JAVA by using a java.sql.CallableStatement, but it seems that nothing happens.

Here is the code that I am using:

 

java.sql.CallableStatement stmt = hanaConnection.prepareCall("{CALL MY_SP(?)}");

stmt.setString(1, "test"); 

boolean result = stmt.execute(); 

stmt.close();

 

but result is false. I have tried also by using stmt.executeBatch(); but nothing!

 


Please can someone help me? What I am doing wrong?

 

Thank you,

Gennaro.


Viewing all articles
Browse latest Browse all 6745

Trending Articles