How to add child element in DB response mapping with proper

Posted by Admin on 04-Jan-2010 11:30

We'd like to add a child element from the DB response to the existing document, the element is abled to be added using the blank namespace looks like this <Id xmlns="">, what we'd like to do is to using the namespace definied in the xml document, or using default namespace, not the blank namespace, is there a way doing it? Thanks.

All Replies

Posted by Bill Wood on 06-Jan-2010 09:47

(I replied with a similar note on your other comment wrt the Mapping Guide.)

The "Insert as Child Node" capability does copy the nodes as is into the target document.  You can't reparent their namespace or modifiy them.   The prescribed architecture would be to:

  •   insert this (and other XML nodes) as child elements into a common XML
  •   run a transformation step to modify the XML.

The "Insert as Child Node" is intended to let you create a single XML document, which is easier for the XML Transformation service to deal with than having multiple parts that need to be combined.

(There is an alternative that may work in the ESB DB file -- you can specify a mapping between output variables and output parameters.   It may be possible to modify the XML in the esbdb file, so that you would have an XML parameter that could be inserted correctly with no post processing).

This thread is closed