db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ramin Moazeni" <rmoaz...@gmail.com>
Subject Regarding DERBY-2685
Date Tue, 12 Jun 2007 19:03:53 GMT
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

Mime
View raw message