Forum Discussion

Sahil's avatar
Sahil
Contributor
5 years ago
Solved

Getting unwanted xml tag

Hi,
I am getting unwanted tags in my output xml.
such as

How do I avoid it.
My pipeline looks like below:-

  • @Sahil I think you already make root element, so delete the extra mapper as I suggest. It should work.(only removing the DocumentRoot from xml formatter)

3 Replies

  • Supratim's avatar
    Supratim
    Contributor III

    @Sahil add another mapper after mapper1, then use $ = your_root_ele_name like screenshot and remove DocumentRoot from xml formatter. Should work.

    • Sahil's avatar
      Sahil
      Contributor

      Hi @Supratim ,
      Thanks for reply!
      I tried like below but getting two root node.


      Output:-

      • Supratim's avatar
        Supratim
        Contributor III

        @Sahil I think you already make root element, so delete the extra mapper as I suggest. It should work.(only removing the DocumentRoot from xml formatter)