Need to add xml tag in the request message

Hello Experts,
Need ur help.
Right now i am working on the scenario Http -> to -> Proxy.
Whatever request i am getting is not having XML tag in it, and because of that my mapping is failing.
Can you tell me that how can i add XML tag in my request so it will not fail in Mapping?
Need to add : <?xml version="1.0" encoding="UTF-8"?> in request.
Thanks,
Hetal

HI Hetal
Instead of adding this to the source message. Remove this tag from mapping.
Use a XSLT mapping without this initial tag. it will work.
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="2.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:m="http://namespace">
<xsl:output method="xml" version="1.0" encoding="UTF-8" indent="no"/>
<xsl:template match="/">
<xsl:for-each select="//tag">
<xsl:value-of select="." disable-output-escaping="yes"/>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>
Use this mapping without
<?xml version="1.0" encoding="UTF-8"?>
If you still see XML tag then use
<xsl:output method="html"
instead of
<xsl:output method="xml"
Thanks
Gaurav

Similar Messages

  • XML structure of the request message

    Hi Experts,
    I am working on synchronous scenario
    .Net Appl ->SAP-XI -> SAP ECC
    The request from .Net Application will consists of 6 fields.
    A field : Mandatory
    B field : Mandatory
    C field : Mandatory  and should be able to read multiple line item
    D field : Not Required and will be defaulted to 1
    E field : Mandatory  if field F is not entered
    F field : Mandatory  if field E is not enetred.
    I have to create the WSDL file of the above request and provide it to .Net team. The field condition
    will be done in the application level of the sender side.That means it is 1 to 1 mapping of the senders
    request and receivers request.
    Note : A, B, D are header items, rest are line items.
    I have doubt on the following:
    1. Would I have to create 1 parent node under which Header will be there  and all the line items will be under this header node.
    2. What would be the cardinality of the header node , line item node and all other fields especially field C (1: unbounded).
    Best Regards
    Alice Rebecca
    Edited by: Alice@xi on Dec 18, 2011 3:44 PM

    Hello,
    1. Would I have to create 1 parent node under which Header will be there and all the line items will be under this header node.
    Yes, you would need to create a parent node, but with regards to which line items will belong a which header, you need to consult with the sender.
    2. What would be the cardinality of the header node , line item node and all other fields especially field C (1: unbounded).
    Root
    A (1..1) (mandatory)
    B (1..1) (mandatory)
    C (1..unbounded) (C belongs to which header?)
    D (1..1) (defaults to 1)
    E (0..1) (E belongs to which header?)
    F (0..1) (F belongs to which header?)
    Hope this helps,
    Mark

  • Add XML tag to the XML output File

    Experts,
    My Scenario is JDBC to File
    For the resultant xml file i have to append a line <?Test Line?> after
    <?xml version="1.0" encoding="UTF-8" ?> while passing it to legacy system ?
    From SDN I found that a XSLT Mapping(as second mapping in the Interface mapping) will do the above requirement,
    I got some XSLT Code from SDN to do this
    1) 
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
      <xsl:output method="xml" />
      <xsl:template match="/">
    <!--  add processing instruction -->
      <xsl:processing-instruction
    name="POSTEN">SND="SE03220037090" SNDKVAL="1" REC="SE03220669500" MSGTYPE="ORDERS"</xsl:processing-instruction>
    <!--  copy payload -->
      <xsl:copy-of select="." />
      </xsl:template>
      </xsl:stylesheet>
    2) 
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
      <xsl:output method="xml" />
      <xsl:template match="/">
    <!--  add processing instruction -->
      <xsl:processing-instruction
    name="POSTEN">SND="SE03220037090" SNDKVAL="1" REC="SE03220669500" MSGTYPE="ORDERS"</xsl:processing-instruction>
    <!--  copy payload -->
      <xsl:copy-of select="." />
      </xsl:template>
      </xsl:stylesheet>
    But none of them worked for me, the additional tag does not appear on the o/p xml file
    Any help would be appreciated
    Srinivas

    Hello Srinivas,
    I had achieved the same using java mapping:
    Suppose your XML structure is:
    <?xml version="1.0" encoding="UTF-8" ?>
    <Root Element>----
    </Root Element>
    you can use the following code:
              import java.io.*;
              import java.util.*;
              import com.sap.aii.mapping.api.*;
              public class AddCommentInXML implements StreamTransformation {
              String record=null;
              String comment=null;
              public void execute(InputStream in, OutputStream out) {
              try {
              DataInputStream stdin = new DataInputStream(in);
              int length = getLengthFromStream(stdin);
              stdin.reset();
              byte[] buffer = getBytesFromStream(stdin);
              String str = new String(buffer);
              record = "<Root Element>";
              comment ="<!Test Line><Root Element>";
              str = str.replaceAll(record,comment);
              out.write(str.getBytes());
              out.close();
              } catch (IOException e) {
              public int getLengthFromStream(InputStream is ) throws
              IOException{
              int i = 0;
              int length = 0;
              try{
              while ((i = is.read())> 0){
              length ++;
              }catch (ArrayIndexOutOfBoundsException e) {
              e.printStackTrace();
              return length;
              public byte[] getBytesFromStream(InputStream is) throws
              IOException {
    //             Create the byte array to hold the data
              byte[] bytes = new byte[getLengthFromStream(is)];
              is.reset();
    //             Read in the bytes
              int offset = 0;
              int tmp = 0;
              while (offset < bytes.length
              && (is.read(bytes, offset, offset +
              (tmp = is.available()))) > 0) {
              offset += tmp;
    //             Ensure all the bytes have been read in
              if (offset < bytes.length) {
              throw new IOException("Could not completely read Inputstream");
    //             Close the input stream and return bytes
              is.close();
              return bytes;
              public void setParameter(Map param) {
    Hope this helps.
    Regards,
    Shweta

  • InDesign crashes when I add xml tag

    I have some groups (image + text) inside text.
    When I try to add xml tags with a grep query InDesign crashes.
    If I try to manually add xml tag to the text in a group, for example "evitare l'umidità", InDesign give me a message error.
    I think it's a bug
    Here there is the document Dropbox - ProblemaTag.idml
    Thanks
    Ivan

    I haven't done a Book in CS6 yet, but I'm starting to wonder if there might be some sort of bug (not extremely likely, but....) that's new. We had another post yesterday where ID crashed when trying to move a particular file into the chapter 5 position.
    Can you add this file first, then move it to the correct spot after the other files are added?

  • Add xml Tags in Indesign CS4 by Apple/Java script

    Hi,
    All, I'm new to Indesign Scripting, and I'm hoping someone can help me with the following add xml tags in my xml indesign cs4 files.
    I have IDML (ETMV2) xml Indesign CS4 files. But i have lots of powermath equation without xml tags. So i want how i can insert xml tags.
    My probleam like this =>
    <no open xml tags>[&x^{2}+y_{3}&]<no close xml tags>
    I want like this (But i do manualy)
    <inlineequation><inlinemediaobject><textobject role="xpressmath">[&x^{2}+y_{3}&</textobject></inlinemediaobject></inlineequation>
    Can anyone write/suggest me how i can add xml Tags. By Apple/Java Script
    Any insight is appreciated!
    snegig

    Hi,
    John Hawkinson thank you so much your suggestion.
    I am new  this type of discusion (on this page). So i think anybody could not replay my answer. So i repost my question.
    I want insert tags in my Indesign CS4 files. Is this posible when i select my powermath equaiton then run script. Script add tags automatically before/after my equation. Please ignore IDML word.
    Yes i an comfortable with XSLT presently i working with Pearson ETMV2.
    I have one more question when i past my snapshot its appear properly but when i agin see my commant then my snapshot disappear (see small blue rectangle).
    Thank you John again i am new in this industry please guide.
    snegig

  • Add xml Tags by Apple/Java script

    Hi,
    All, I'm new to Indesign Scripting, and I'm hoping someone can help me with the following (add xml) problem.
    Can anyone write/suggest me how i can add xml tags. By Apple/Java Script
    My Probleam =>
    [&x+2, y+3&]
    Solution => (But its manual)
    <inlineequation><inlinemediaobject><textobject role="xpressmath">[&x+2, y+3&]</textobject></inlinemediaobject></inlineequation>
    I want add xml tags on my powermath equaiton. Its ETMV2 xml tags.
      Any insight is appreciated!
    Thank you so much
    snegig

    Hi John,
    (1) Without xml tags my InDesign file
    (2) After add tags my file (its manually)
    Is this any script when i select my power math equation data then add xml tags automatically
    Thank's any suggestion

  • PDF PO Release - XML Tags for the Header and Line Attachments

    Hi,
    I request you to please help me in finding out the XML tags for the PDF PO Release Header and Line Attachments? I tried to get the XML data by running the 'PO Output for Communication' program with the parameter as 'Debug' but its completing normally without giving me the XML data in the log file.
    Please help me in finding the XML tags for the PDF PO Release for the Header and Line Attachments.
    Thanks,
    Kunal

    Hi Kunal,
    Following syntax will get you the header and line level short and long text attachments.
    --Header short text attachments
    <?for-each:HEADER_SHORT_TEXT_ROW?>
         <?SHORT_TEXT?>
    <?end for-each?>
    --Header long text attachments
    <?for-each:/PO_DATA/HEADER_ATTACHMENTS/LONG_TEXT?>
         <?.?>
    <?end for-each?>
    --Line short text attachments
    <?for-each:LINE_SHORT_TEXT_ROW?>
         <?SHORT_TEXT?>
    <?end for-each?>
    --Line long text attachments
    <?variable@incontext:PoLnID;'PO_LINE_ID'?><?for-each:/PO_DATA/LINE_ATTACHMENTS/ID[. =$PoLnID]?>
         <?current()[$PoLnID]/preceding-sibling::TEXT[1]?>
    <?end for-each?>
    Also note that, while running the program in Debug mode for a particular PO/Release the status should be INCOMPLETE, otherwise you won't be able to see the XML tags.
    Thanks,
    PS.
    Edited by: PS on Sep 25, 2012 6:16 AM

  • Need to add a link to the masthead area of the Portal

    Hi
    I need to add a link to the masthead area of the portal. That link needs to be able to print the content of the current page.
    Ihave downloaded the com.sap.portal.navigation.masthead into the NWDS.
    Can anybody please let me know where exactly to modify the code.
    i am guessing i may need to use window.print() to print the page.
    Thanks
    Sharath
    Thanks
    Sharath

    Step 1: Adding new link in the masthead
    1. Rename the par file to your own namespace and import the PAR using eclipse
    2. To add your link - modify HeaderiView.jsp appropriately
    3. Build the PAR and export using Eclipse
    Step 2: Create an iView
    1. Content Administrator -> Portal Content -> Select the folder in which you need to create the masthead iView. Right click on the selected folder and "Select New From PAR" -> iView
    2. Select the PAR file name created by you in Step 1 a
    3. Choose "default" in Portal Component Selection
    4. Provide the properties for the iView and save
    Step 3: Modify Portal Masthead
    1. Add the iView created in Step 2 to the Framework Page of your application
    2. Remove the existing Masthead iView from the framework page and add iView created in Step 2 in the framework page.
    3. Note that the position should be the same where the previous masthead is removed.
    Logoff and logon with the user who is assigned the framework page - you should be able to see the new masthead with links
    Incase you are changing the default framework page and default masthead ensure that you have a backup so that you can revert.

  • I'm creating an epk and I need to add a bio to the menu.  Can I import the text file or do I need to retype the bio somewhere?  What is the best way to proceed?

    I'm creating an epk and I need to add a bio to the menu.  Can I import the text file or do I need to retype the bio somewhere?  What is the best way to proceed?

    Electronic Press Kit.
    Usually in the form of video outtakes, movie trailers, cast and crew interviews. Basically, the stuff that gets bunged onto commercial DVDs as extras or ends up on late night TV "Making Of..." shows.
    To answer the OP, you want a button on the menu that leads to a still image, or series of them, set up as a slide show. You can copy/paste the text in DVD Studio and then add formatting via the Text menu. (Highlight the text and right click to access formatting controls). Or do it in a graphics application using the appropriate video image preset.

  • Edit JS Script CS4 (Add XML Tags All pages automatically)

    Hi, all Scripter
    I have a javascript for add xml tags (ETMV2 Pearson, InDesign CS4).  We have select my powermath equation data then run script. Script automatically insert xml tags both side (open/close). But we select one by one then run script its time taking.
    var d=app.activeDocument,
    root=d.xmlElements[0],
    ie = root.xmlElements.add("inlineequation", app.selection[0]),
    im = root.xmlElements.add("inlinemediaobject", ie.texts[0]),
    to = root.xmlElements.add("textobject", im.texts[0]);
    to.xmlAttributes.add("role", "xpressmath");
    Example 1: My powermath equation data (InDesign CS4)
    [&x^{2}+y *frac*{1}{2x}&]
    Select powermath equation data then run javascript below mention. Script insert xml tags.
    <inlineequation><inlinemediaobject><textobject>[&x^{2}+y *frac*{1}{2x}&]</inlineequation></inlinemediaobject></textobject>
    Its time taking and select one by one
    Result:
    My main concern is that is this possible script find open [& and close &] all poermath equation data automatically then insert (add) xml tags all pages.
    Thank/Regard
    snegig

    Hi,
    John Hawkinson thank you so much your suggestion.
    I am new  this type of discusion (on this page). So i think anybody could not replay my answer. So i repost my question.
    I want insert tags in my Indesign CS4 files. Is this posible when i select my powermath equaiton then run script. Script add tags automatically before/after my equation. Please ignore IDML word.
    Yes i an comfortable with XSLT presently i working with Pearson ETMV2.
    I have one more question when i past my snapshot its appear properly but when i agin see my commant then my snapshot disappear (see small blue rectangle).
    Thank you John again i am new in this industry please guide.
    snegig

  • Need an add on that changes the tabs like pages of an book

    need an "add on" that changes the tabs like pages of an book. I had this years ago, but dont remember the name and how to find it. Thanks

    Maybe this extension or one of the others mentioned has that feature:
    Tab Utilities: https://addons.mozilla.org/firefox/addon/59961

  • Need to add a Transaction in the SAP menu in the Given path

    Hi All,
    I need to add a transaction in the enhancement menu in the specified path.
    Kindly share the method.
    Thanks in Advance!
    Chirag Shah

    Hi ,
    Go to SE43 and give the AREA MENU , and press the create button and add the Tcode...
    Regards,
    Bharani

  • Urgent -Need to Add new values for the LOV field in forms

    HI,
    I am customizing an existing form. In that i need to add some values for the LOV fied which can be used during run time.
    Please Can some one help me in doing this?
    Thanks
    Suresh P

    Go to Navigator and edit the LOV or create a new one.
    hope that helps!

  • Add XML tag (all power math equation) after/before

    Hi all,
    I have JS code written by (Sir John Hawkinson "http://forums.adobe.com/thread/938603?tstart=90") its work fine. Actually script do add XML tags [&x+2&] after/before this power math equation.
    My problem when i run this script i am select matter (power math equation) one by one is that possible when i select few paragraph script add automatic xml tags select all "power math equation" matter.
    script code below:
    var d=app.activeDocument,
        root=d.xmlElements[0],
        ie = root.xmlElements.add("inlineequation", app.selection[0]),
        im = root.xmlElements.add("inlinemediaobject", ie.texts[0]),
        to = root.xmlElements.add("textobject", im.texts[0]);
    to.xmlAttributes.add("role", "xpressmath");
    Thank's
    Regard
    snegig

    Hello Sir,
    That time you suggest lots of possibility this script code. But 2 and 3 month i am very new in (InDesign, JS and my first jobs) so i have heavy workload so.
    I am really sorry once again could you any change/update this code.
    Thank you so much once again
    Regard
    snegig

  • JAXB / Needs to add header tag and close the header tag at the bottom

    I have successfully generated a XML file based on the XSD. I want to add another tag to my generated XML which is not the part of the XSD. Its like adding my whole xml inside a new tag. Is there a way to achieve it?User_10111723083878.xml
    to this xml, I want to add as the parent element "<addRequest targetID="BottomLineTarget" executionMode="asynchronous" xmlns="urn:oasis:names:tc:SPML:2:0">
    <data>" and close it at the bottom of the xml.
    Is it possible?

    the easiest way would be to create an xsd which includes this new wrapper element, and wrap the original object with your new wrapper object before serializing.
    an alternative would be to serialize the original object into a DOM object, then add the wrapper element manually before serializing that DOM object to your final destination (e.g. the xml file).

Maybe you are looking for

  • Graph.xml not rendering correctly

    Hi! I've been working on a pie chart for a while and i'm striving to refine it. Here's my code: *<rw:graph id="CT_1" src="nnnnnnn" series="nnnnn" dataValues="nnnnn">* *<!--* *<?xml version="1.0" ?>* *<Graph version="3.2.0.22" graphType="PIE" depthAng

  • My right arrow key isnt working.

    My right arrow key is not working. Well, I mean I can press on it and it will move sometime but I have to use a lot of force to make it move. Is something stuck under there (can I get it out by myself?) or do I need to go into the apple store?? Thank

  • IPhoto 9.5 - Cannot create a book anymore, causes iPhoto to freeze have to force quit

    Ive had my new imac 5 days been creating a book all week, Was asked to create a new one for a family member but could not create a new book i can create a card or calender just not a book.

  • Color Picker scripting or Levels algorithm help

    First question is: Does anyone know of a good explanation of the Levels algorithm as in how each setting affects a pixel in an image. If I change the midpoint of the levels, how would a specific pixel change in relation to that? I've been experimenti

  • Why can't I watch a video?

    I try to watch a video on iPad and it won't work.