title: Oracle 11g : ORA-22284 on insertion into table with CLOB field > ~1350 chars
body: <p>I'm running into trouble trying to perform a merge into a table containing a CLOB field.</p>
  
  <p>I'm working with a .Net FrameWork v4.5 codebase that generates an SQL statement as follows:</p>
  
  <pre><code>MERGE INTO md_metadata.md_report_templates TARGET
  USING (SELECT 1
         FROM   dual)
  ON (TARGET.id=:template_id)
  WHEN matched THEN
    UPDATE SET title = :title,
               description = :description,
               xml_data = :xml_data,
               technology = :technology,
               modification_date = :modification_date,
               reports_list = :reports_list
  WHEN NOT matched THEN
    INSERT(id,
           title,
           description,
           xml_data,
           is_private,
           technology,
           owner,
           modification_date,
           reports_list)
    VALUES(:template_id,
           :title,
           :description,
           :xml_data,
           :is_private,
           :technology,
           :owner,
           :modification_date,
           :reports_list);  
  </code></pre>
  
  <p>Here xml_data is an CLOB field.  The intent of this statement is into insert (or update) a row into the table that contains an XML description of a form template.  This statement works fine as long as the :xml_data parameter length does not exceed ~1350 characters or ~2700 bytes.  As soon as this happens the Oracle Data Access Client (4.121.1.0) throws up an exception 'ORA-22284 Duplicate long binds are not supported'.</p>
  
  <p>I'm baffled.  Can anyone shed any light on why this occurs?</p>
  
  <p>If the row is inserted with a shorter value in :xml_data, and then updated in a separate statement with the original (1350+ ch) value in :xml_data, this works as desired!</p>
  
  <p>Thanks,</p>
  
  <p>DC</p>