org.springframework.dao.InvalidDataAccessApiUsageException: Unable to determine the correct call signature - no procedure/function/signature for 'PROCONEINPARAMETER'

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • No procedure/function/signature
    via Stack Overflow by deltaVee
    ,
  • Try these with an empty (for example in memory, derby) database: {code:java} new SimpleJdbcCall(jdbcTemplate).withProcedureName("bar").compile(); {code} {code:java} new SimpleJdbcCall(jdbcTemplate).withProcedureName("foo.bar").compile(); {code} The first one passes but the second one throws an exception (below). I think both should throw an exception (as there are no stored procedures with those names in the database). The issue seems to be in [GenericCallMetaDataProvider.processProcedureColumns()|https://github.com/spring-projects/spring-framework/blob/master/spring-jdbc/src/main/java/org/springframework/jdbc/core/metadata/GenericCallMetaDataProvider.java#L333] (code is the same in 4.0.x and master branches). It throws an exception in case more than one sprocs are found and also in case no sproc was found and the name contains a "." It seems it is missing an else branch to throw an exception for other not found sprocs as well. {noformat} org.springframework.dao.InvalidDataAccessApiUsageException: Unable to determine the correct call signature for FOO.BAR - package name should be specified separately using '.withCatalogName("FOO")' at org.springframework.jdbc.core.metadata.GenericCallMetaDataProvider.processProcedureColumns(GenericCallMetaDataProvider.java:328) at org.springframework.jdbc.core.metadata.GenericCallMetaDataProvider.initializeWithProcedureColumnMetaData(GenericCallMetaDataProvider.java:104) at org.springframework.jdbc.core.metadata.CallMetaDataProviderFactory$1.processMetaData(CallMetaDataProviderFactory.java:128) at org.springframework.jdbc.support.JdbcUtils.extractDatabaseMetaData(JdbcUtils.java:290) at org.springframework.jdbc.core.metadata.CallMetaDataProviderFactory.createMetaDataProvider(CallMetaDataProviderFactory.java:71) at org.springframework.jdbc.core.metadata.CallMetaDataContext.initializeMetaData(CallMetaDataContext.java:269) at org.springframework.jdbc.core.simple.AbstractJdbcCall.compileInternal(AbstractJdbcCall.java:279) at org.springframework.jdbc.core.simple.AbstractJdbcCall.compile(AbstractJdbcCall.java:266) {noformat} The reason why it would be good to have an early exception is to catch missing stored procedures during application startup (when the SimpleJdbcCall is created and compiled) instead only when it is used (sproc is called).
    via by Attila Király,
    • org.springframework.dao.InvalidDataAccessApiUsageException: Unable to determine the correct call signature - no procedure/function/signature for 'PROCONEINPARAMETER' at org.springframework.jdbc.core.metadata.GenericCallMetaDataProvider.processProcedureColumns(GenericCallMetaDataProvider.java:347) at org.springframework.jdbc.core.metadata.GenericCallMetaDataProvider.initializeWithProcedureColumnMetaData(GenericCallMetaDataProvider.java:112) at org.springframework.jdbc.core.metadata.CallMetaDataProviderFactory$1.processMetaData(CallMetaDataProviderFactory.java:133) at org.springframework.jdbc.support.JdbcUtils.extractDatabaseMetaData(JdbcUtils.java:299) at org.springframework.jdbc.core.metadata.CallMetaDataProviderFactory.createMetaDataProvider(CallMetaDataProviderFactory.java:73) at org.springframework.jdbc.core.metadata.CallMetaDataContext.initializeMetaData(CallMetaDataContext.java:286) at org.springframework.jdbc.core.simple.AbstractJdbcCall.compileInternal(AbstractJdbcCall.java:303) at org.springframework.jdbc.core.simple.AbstractJdbcCall.compile(AbstractJdbcCall.java:288) at org.springframework.jdbc.core.simple.AbstractJdbcCall.checkCompiled(AbstractJdbcCall.java:348) at org.springframework.jdbc.core.simple.AbstractJdbcCall.doExecute(AbstractJdbcCall.java:375) at org.springframework.jdbc.core.simple.SimpleJdbcCall.executeFunction(SimpleJdbcCall.java:153) at test.jdbc.StringDao.executeProcOneINParameter(StringDao.java:21) at test.jdbc.SimpleJdbcTest.main(SimpleJdbcTest.java:15)
    No Bugmate found.