Project: Birt
Bug 234078 [Regression]Can not get the value of output parameter in storeprocedure
Reported: 2008-05-27 02:53:34 | Status: closed fixed

Description: [Regression]Can not get the value of output parameter in storeprocedure Build number: 2.2.0.v20061107-0630 Steps to reproduce: 1, Create a procedure like: ALTER PROCEDURE [dbo].[counterInT1] @counter int output AS select @counter=count(*) from T1 Or use the stored procedure counterInT1 in jdbc:jtds:sqlserver://spmdb/gui 2, New a stored procedure dataset and call procedure 3, Change the output parameter to Output type 4, Preview Output parameter Expected result: The value of @count can be retrieved Actual result: Exception throws out Error log: org.eclipse.birt.data.engine.core.DataException: Cannot fetch the next data row. ResultSet cannot be null. at org.eclipse.birt.data.engine.odaconsumer.ResultSet.throwDataException(ResultSet.java:493) at org.eclipse.birt.data.engine.odaconsumer.ResultSet.throwDataException(ResultSet.java:485) at org.eclipse.birt.data.engine.odaconsumer.ResultSet.fetch(ResultSet.java:139) at org.eclipse.birt.data.engine.executor.cache.OdiAdapter.fetch(OdiAdapter.java:145) at org.eclipse.birt.data.engine.executor.cache.RowResultSet.next(RowResultSet.java:102) at org.eclipse.birt.data.engine.executor.transform.SimpleResultSet.<init>(SimpleResultSet.java:64) at org.eclipse.birt.data.engine.executor.DataSourceQuery.execute(DataSourceQuery.java:590) at org.eclipse.birt.data.engine.impl.PreparedOdaDSQuery$OdaDSQueryExecutor.executeOdiQuery(PreparedOdaDSQuery.java:331) at org.eclipse.birt.data.engine.impl.QueryExecutor.execute(QueryExecutor.java:801) at org.eclipse.birt.data.engine.impl.ServiceForQueryResults.executeQuery(ServiceForQueryResults.java:233) at org.eclipse.birt.data.engine.impl.QueryResults.getResultIterator(QueryResults.java:160) at org.eclipse.birt.report.designer.data.ui.dataset.OutputParameterPreviewPage.updateResults(OutputParameterPreviewPage.java:259) at org.eclipse.birt.report.designer.data.ui.dataset.OutputParameterPreviewPage.access$1(OutputParameterPreviewPage.java:196) at org.eclipse.birt.report.designer.data.ui.dataset.OutputParameterPreviewPage$2.run(OutputParameterPreviewPage.java:171)

Files changed in fix:
data/org.eclipse.birt.report.data.oda.jdbc/src/org/eclipse/birt/report/data/oda/jdbc/CallStatement.java