AnsweredAssumed Answered

Select from Database Operator - prepareCall used erroneously

Question asked by Klaus.Nuber on Nov 18, 2016
Latest reply on Apr 13, 2017 by Klaus.Nuber

Hello,

 

I'm using the Select from Database Operator with a JDBC Driver which is not in the list, so I use the Database type "other"

 

As input source "Inline Text" and the SQL statement is "SELECT * FROM KUNDE" (without the quotes)

 

The call fails with [DBAccess-Server] SEV9V18 STATEMENT TYPE IN PREPARECALL MUST BE CALL STATEMENT.

 

This is the call stack:
java.sql.SQLException: [DBAccess-Server] SEV9V18 STATEMENT TYPE IN PREPARECALL MUST BE CALL STATEMENT.
    at de.siemens.sesam.dbaccess.SesamResponder.readDBError(SesamResponder.java:670)
    at de.siemens.sesam.dbaccess.SesamResponder.readStatus(SesamResponder.java:424)
    at de.siemens.sesam.dbaccess.SesamResponder.readPrepareCall(SesamResponder.java:1125)
    at de.siemens.sesam.dbaccess.SesamPrepareStatement.doCall(SesamPrepareStatement.java:94)
    at de.siemens.sesam.dbaccess.SesamDBAccess.invokeStatement(SesamDBAccess.java:725)
    at de.siemens.sesam.dbaccess.SesamDBStatement.prepareCall(SesamDBStatement.java:888)
    at de.siemens.sesam.dbaccess.SesamPreparedStatement.<init>(SesamPreparedStatement.java:156)
    at de.siemens.sesam.dbaccess.SesamCallableStatement.<init>(SesamCallableStatement.java:70)
    at de.siemens.sesam.dbaccess.SesamConnection.prepareCall(SesamConnection.java:1844)
    at de.siemens.sesam.dbaccess.SesamConnection.prepareCall(SesamConnection.java:461)
    at com.optinuity.c2o.service.serviceoperation.jdbcserviceoperation.JDBCGenericWrapper.executeSQL(JDBCGenericWrapper.java:220)
    at com.optinuity.c2o.service.serviceoperation.jdbcserviceoperation.RunnerJDBCSelectServiceOperation.processRequestedOperation(RunnerJDBCSelectServiceOperation.java:405)
    at com.optinuity.c2o.service.serviceoperation.jdbcserviceoperation.RunnerJDBCSelectServiceOperation.run(RunnerJDBCSelectServiceOperation.java:77)
    at java.lang.Thread.run(Thread.java:745)

 


The JDBC Standard specifies that prepareCall is for preparing stored procedure.

 

For a simple SQL statement the prepareStatement should be used.

 

Is there a setting to change this behaviour? Or might this be an bug?

Outcomes