Problem with stored procedures after migration from mysql to mariadb with jdbc driver from mariadb

You are viewing an old version of this question. View the current version here.

This is the main Knowledge Base category for MariaDB.

Follow any of the links below to find information on the topics you are interested in. If you would like to know more about anything that isn't documented, ask a question at the place where the answers should be and we will do our best to provide an answer for it!

Answer

Hi, This was happening because following the JDBC API, a call to CallableStatement.executeQuery() must return a resultset (method inheritance from http://docs.oracle.com/javase/7/docs/api/java/sql/PreparedStatement.html#executeQuery())

You'll tell if i'm correct, but i assume the query {call spmzBenutzer(...)} must not have any resultset. That why this exception was thrown.

I agree this is too harsh. Version 1.4 is released with a rewritten implementation of CallableStatement. Now, In this case, no exception is thrown, just an empty resultset (i've just test it and this is similar to what the MySQL connector is doing).

Comments

Comments loading...
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.