title: How to registerOutParameter of type Raw in Java
body: <p>I have Oracle procedure named enter that returns RAW type as result.When I want to register out parameter named 'ret' I get this error : </p>
  
  <pre><code> java.sql.SQLException: Parameter Type Conflict: sqlType=-2
  </code></pre>
  
  <p>This is my java method and import statement: </p>
  
  <pre><code>import org.apache.openjpa.jdbc.sql.Raw;
  
  public Raw enter(int pid) {
      Connection connection;
      CallableStatement cstmt;
      try {
          connection = cscadaDataSource.getConnection();
          connection.setAutoCommit(false);
          cstmt = connection.prepareCall("{ CALL process_logging.PROCESSMONITOR_ENTER(?,?) }");
          cstmt.setInt(1, pid);
          cstmt.registerOutParameter(2,OracleTypes.RAW , "ret");
          cstmt.execute();
  
          Raw result = (Raw) cstmt.getObject(2);
  
          connection.commit();
          return result;
      } catch (SQLException e) {
          // TODO Auto-generated catch block
          e.printStackTrace();
      }
      return null;
  
  }
  </code></pre>
  
  <p>How can I get this output parameter of RAW type in Java? 
  Thanks in advance!</p>