title: What is the jdbc type and java type for LONG RAW column?
body: <p>I am facing a strange issue. I have a table <code>file_data</code>. It has a column called <code>filedata</code> and the data type is <code>long raw</code>. In this column a hexadecimal representation of an excel file gets stored like <code>D01A01....</code>. Now I have a procedure called 'PROC_STORE_DATA'. I am calling this procedure from my java class and trying to insert an excel spreadsheet content inside that table column.</p>
  
  <p>In my Java class, I am getting the file content like this:</p>
  
  <pre><code>byte[] bytes = fileData.getBytes();
  StringBuffer hexSt = new StringBuffer();
  for(byte b : bytes){
      hextSt.append(Integer.toHexString(b &amp; 0xff));
  }
  </code></pre>
  
  <p>I  have a hashmap called procData where in I push this <code>hexSt</code> variable.</p>
  
  <pre><code>procData.put('fileData',hextSt.toString().toUpperCase());
  </code></pre>
  
  <p>Then, I call my update method to update the table via my procedure:</p>
  
  <pre><code>myUpdateDao().update(PROC_STORE_DATA,procData);
  </code></pre>
  
  <p>In mybatis.xml, this is how I have defined the column to be updated in the parameter map:</p>
  
  <pre class="lang-xml prettyprint-override"><code>&lt;parameterMap&gt;
      &lt;parameter property="updatefileData" javatype="java.lang.String" jdbcType="LONGVARCHAR"&gt;
  &lt;/parameterMap&gt;
  </code></pre>
  
  <p>But after running this, I get this error: <code>wrong number or types of arguments in the procedure call - PLS-00306 and ORA-06550</code>. </p>
  
  <p>I have spent 2 days and yet I don't understand where the issue is. The issue may be with javaType and jdbcType, but I am not sure what should I give as javaType and jdbcType here for a column with data type <code>LONG RAW</code> .</p>
  
  <p>After using <code>longvarbinary</code> and <code>byte[]</code> as mentioned in the answer by ewramner,
  I am getting a class cast exception: <code>java.lang.String</code> cannot be converted to <code>[L java.lang.Byte</code></p>