How to parse unresolved result set in Tibco BW JDBC palette

江枫思渺然 提交于 2019-12-07 02:59:26

For me sounds like converting procedure output UnresolvedResultsets to column/value schema can help to resolve your issue. You can use standard "Transform XML" activity for transforming $JDBC-Procedure/resultSet/UnresolvedResultsets to column/value schema

Step1 create XSLT file with following content:

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 
xmlns:str="http://exslt.org/strings" 
xmlns:tns="http://www.*****.com/DMS/Core/Schemas/Index/Schema.xsd" 
version="2.0">
   <xsl:output method="xml" encoding="UTF-8" indent="yes" />
   <xsl:template match="/">
    <xsl:element name="ROOTELEMENT">
     <xsl:for-each select="//node()[not(exists(child::*))]">
        <xsl:if test="name()">
           <xsl:element name="Column">
              <xsl:element name="Name">
                 <xsl:value-of select="name()" />
              </xsl:element>
              <xsl:element name="Value">
                 <xsl:value-of select="." />
              </xsl:element>
           </xsl:element>
           </xsl:if>
         </xsl:for-each>
      </xsl:element>
   </xsl:template>
</xsl:stylesheet>

Step 2 add "Transform XML" activity and specify created in step 1 xslt file as Stylesheet

Step3 map $JDBC-Procedure/resultSet/UnresolvedResultsets to Transform XML input

The result should be like this:

here is link to transform XML tutorial

Boosa Liberman

You can try ParsigXML using an "Any Element":

and this is the output i am parsing by:

Hope it works for you.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!