I am trying to call a legacy stored function in an Oracle9i DB from Java using Hibernate. The function is declared like this:
create or replace FUNCTION Tran
For further reference, here is my final solution:
CallableStatement statement = session.connection().prepareCall( "{ ? = call Transferlocation_Fix(?) }"); statement.registerOutParameter(1, Types.VARCHAR); statement.setString(2, "FC3"); statement.execute(); String result = statement.getString(1);