DataPower

DataPower

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  How to convert String to BLOB in Datapower XSLT

    Posted Mon January 29, 2024 12:25 AM

    Hi Team...

    I am doing a transformation in Datapower using XSLT and creating an XML message and I wanted to know how to convert String to BLOB in XSLT. This is required as one of the element in output XML should have BLOB data. Please let me know how to convert String to BLOB in Datapower XSLT. Thanks



    ------------------------------
    Ashok Beshra
    ------------------------------


  • 2.  RE: How to convert String to BLOB in Datapower XSLT

    Posted Mon January 29, 2024 08:56 AM

    Generally speaking, you want to use the CDATA element.

    <![CDATA[blob data]]>



    ------------------------------
    Joseph Morgan
    ------------------------------



  • 3.  RE: How to convert String to BLOB in Datapower XSLT

    Posted Tue January 30, 2024 04:47 AM

    Don't create CDATA section yourself, use "cdata-section-elements" instead:
    https://www.w3.org/TR/xslt-10/#output

    In case you want to embed one XML into another without namespace pollution, you need to use dp:serialize, see bottom of this slide:
    https://www.ibm.com/support/pages/system/files/support/swg/swgdocs.nsf/0/505bf6259618fd91852577510065f208/$FILE/WSTE-07082010-WebSphereDataPowerSOAAppliancesXSLTPart2of2TipsTricks-Stamm-Wilbrandt.pdf#page=9



    ------------------------------
    Hermann Stamm-Wilbrandt
    Compiler Level 3 support, IBM DataPower Gateways
    IBM
    Boeblingen Germany
    ------------------------------