This content has been marked as final. Show 6 replies
I don't think BAM adapter is capable of parsing the xml payload to insert multiple rows using one input. Each adapter invocation is treated as one operation and the fields are mapped using xsl from input to BAM dataobject fields. Batching is used to cache multiple calls to BAM and send them either on batch timeout or on exceeding the upper limit.
I have done a similar thing. My Sales Order has multiple lines and I need to create one row for each order line present. When you create the BAM sensor action, you will have to use a for-each in the xsl which does the mapping between the payload and BAM data object. For instance, if your BAM data object has fields LineNumber and SubmittedDate and this occurs for each order line, the mapping would like:
<xsl:stylesheet version="1.0" xmlns:ns0="http://xmlns.oracle.com/bam"
exclude-result-prefixes="xsl tns sensor ns0">
Good to know about the workaround where the logic is given in the xsl.
I have the same problem but even after using for-each in the xsl, it is not working. Kindly let us know if we need to do any other step also.
Is there a way we can do this. Even I am facing the issue while inserting multiple rows to BAM through BAM adaptor. The Invoke shows multiple rows being passed but in DO only the first one is stored.
Is it possible to insert multiple lines into a data object using a single BAM Adapter call.. its very easy to to insert. All you need to do is in XSLT use for-earh loop.
this is the example for for each loop.
soa related example
I hope this will be helpful:)