我正在使用Sybase中的存储过程创建WSO2数据服务。每当我将值赋给局部变量时,我都会收到错误。
存储过程如下
...
声明@user_id INT
选择@user_id = 333
....
上面的select语句似乎导致问题并导致以下错误
DS Code: DATABASE_ERROR Nested Exception:- javax.xml.stream.XMLStreamException: DS Fault Message: Error in 'SQLQuery.processStoredProcQuery': The method com.sybase.jdbc3.jdbc.SybCallableStatement.getMoreResults(int) has not been completed and should not be called. DS Code: DATABASE_ERROR Source Data Service:- Name: testAmit Location: \testAmit.dbs Description: N/A Default Namespace: http://ws.wso2.org/dataservice Current Request Name: amitTestOps Current Params: {invId=22} Nested Exception:- com.sybase.jdbc3.utils.UnimplementedOperationException: The method com.sybase.jdbc3.jdbc.SybCallableStatement.getMoreResults(int) has not been completed and should not be called. </soapenv:Text>
如果我评论select语句,它可以正常工作。
我的数据服务看起来像这样
<data name="testAmit" transports="http https local">
<config enableOData="false" id="sybaseAmit">
<property name="driverClassName">com.sybase.jdbc3.jdbc.SybDriver</property>
<property ***db config deatils which I have omitted ***</property>
</config>
<query id="amitquery" useConfig="sybaseAmit">
<sql>exec sp_createCorrespondence ?</sql>
<result element="correspondences" rowName="correspondence">
<element column="correspondence_id" name="correspondenceIdValue" xsdType="integer"/>
</result>
<param name="invId" sqlType="INTEGER"/>
</query>
<operation name="amitTestOps">
<call-query href="amitquery">
<with-param name="invId" query-param="invId"/>
</call-query>
</operation>
</data>
任何帮助都将受到高度赞赏! (使用WSO EI版本6.1.1,jconn3.jar,sybase ASE 15.7)