Search My Ramblings

Thursday, April 11, 2013

Oracle Fusion Middleware-Inserting large XML into XMLType columns

A couple of years ago I ran into this issue with Oracle SOA Suite 10g, and posted on this blog how to resolve it.  Which is great since I used basically the same solution in 11g and it works there as well, only it doesn't require any server changes at all.

If you're trying to save a large XML payload into an XMLType column type in an Oracle database table from a DbAdapter partner link (JCA Adapter in OSB), and receive the error:

ORA-01461: can bind a LONG value only for insert into a LONG column

 You should only need to edit the mappings.xml for that partner link, navigate to the column that is an XMLType in the database, and change the xsi:type from "direct-mapping" to "direct-xml-type-mapping".

Then recompile your SOA composite (or update the OSB mappings file) and redeploy and test.

It should now support larger-size XML payloads!

5 comments:

Rakesh Kumar said...

Hi, I have the same issue. Can you please fill in the blanks? What to replace with what? Hope to hear something soon. Thanks

Rakesh Kumar said...

Hi, I have the same issue. Can you please fill in the blanks? What to replace with what in the mappings.xml file? Hope to hear something soon. Thanks

JLewis said...

Oops, sorry about that. I've updated the posting, hope it helps! You can also look back at my original Oracle SOA Suite 10g posting on this topic located here - http://jameslewisblog.blogspot.com/2009/06/publishing-large-xml-docs-from-bpel-to.html

Rakesh Kumar said...

Thanks a lot for the update. I will give it a try.

Kasim said...

Thanks a lot for the solution.