You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by Ramin Moazeni <rm...@gmail.com> on 2007/06/12 21:03:53 UTC

Regarding DERBY-2685

Hello

I am getting test failures as part of
converting jdbcapi/parameterMetadataJdbc30.java.

The behavior is different between the embedded and the n/w
client. Here are the results:

* Testing with org.apache.derby.jdbc.ClientDriver
getParameterType: 3
* Testing with org.apache.derby.jdbc.EmbeddedDriver
getParameterType: 2

Expected results should be getParameterType: 2

The problem is at the following piece of code:
 /**
         *  test: the scale returned should be the one set by
registerOutParameter
         */
        public void testCallableStatementReturnedScale () throws SQLException {

                Statement stmt = createStatement();
                stmt.executeUpdate("create procedure
dummy_numeric_Proc(out a NUMERIC(30,15), out b NUMERIC(30,15))
language java parameter style java external name
'org.apache.derbyTesting.functionTests.tests.jdbcapi.parameterMetaDataJdbc30.dummy_numeric_Proc'");
                CallableStatement cs = prepareCall("CALL
dummy_numeric_Proc(?,?)");
                cs.registerOutParameter(1, Types.NUMERIC);
                cs.registerOutParameter(2, Types.NUMERIC,15);
                cs.execute();
                assertEquals("Unexpected parameter count", 2,
paramMetaData.getParameterCount());
                assertEquals("Unexpected parameter Type", 2,
cs.getParameterMetaData().getParameterType(1));

                cs.close();

I am attaching a testcase with this email.

Thanks,
Ramin Moazeni