RFC to XI: Payload comes in garbled

We finished and tested our scenario in dev and have moved the code on the abap side as well as the XI pieces to Test.
When sending an RFC from our SAP test system, if I look in the SXMB_MONI, the first node of inbound message payload is already garbled even before getting to the message mapping. The first part of it looks like this:
  <?xml version="1.0" encoding="UTF-8" ?>
- <rfc:Z_BAPI_PRICING_SEND xmlns:rfc="urn:sap-com:document:sap:rfc:functions">
- <PRODUCT_PRICE>
- <item>
  <PROD_ID>000000000001003484</PROD_ID>
  <PRC_TYP_CD>9912</PRC_TYP_CD>
  <CNTRY_CD> e<</CNTRY_CD>
  <EFF_BEGIN_DT>0000-00-00</EFF_BEGIN_DT>
  <EFF_END_DT>0000-00-00</EFF_END_DT>
  <PRC_AMT>0</PRC_AMT>
  </item>
the prod_id is ok
prc_type should have been 'WHL'
country should have been 'US'
etc etc.
It's like the data in the payload doesn't match up with the xml.  In our dev environment all works normally.
any thoughts?
Thanks!

Pete,
Thanks so much! That was exactly the problem. I saved the RFC Dest as unicode and it is now working.  How does the point thing work? I just signed up. Do I have any points to award with?

Similar Messages

  • Saving file, but jpg and gif comes out garbled

    Would someone please help me? I'm at my wit's end here. I'm writing a program that reads a file and saves it, but it needs to read a maximum of 512 bytes before it starts to write. It needs to work with both text files and images.
    - It works fine with text files.
    - It works fine with bmp images.
    - It works fine with jpg and gif images under 512 bytes.
    - With a jpg or gif over 512 bytes, it comes out all garbled, but the same file size as the original.
    One thing is really confoozling me. When the image comes out garbled, I tried changing the files for both the original and the copy into text files by changing the file extension to .txt. Both the text files were identical! So if the data is identical, why is the copy not showing the same image as the original?
    import java.io.*;
         public class SaveFile{
              public static final int BUFSIZE = 512;
              public static final String LIBRARY = "C:\\";
              static int totalRead = 0;  //Total number of bytes in buffer (Max BUFSIZE).
              static int fileSize = 0;  //Size of whole file.
                  static String fileName = "";  //Name of file.
                 static char[] data = new char[BUFSIZE];  //The data in the file.
              public static void main(String[] args){
                            //Bytes already read by the buffer.
                      int charsRead = BUFSIZE; 
                          //Takes name of file from main argument.
                         for(int i=0; i < args.length; i++)
                             fileName = fileName + args;
    //Name of file including directory.
              String fetchFile = LIBRARY + fileName;
              File file1 = new File(fetchFile);
              * Reads a string from the file to data (char array).
                   BufferedReader reader =
    new BufferedReader(new FileReader(file1), BUFSIZE);
                   BufferedWriter writer =
    new BufferedWriter(new FileWriter(fileName));
                   //Will continue as long as buffer is full.
                   while (charsRead == BUFSIZE){ 
                        charsRead = reader.read(data, 0, BUFSIZE);
                        if (charsRead != -1) {
                             totalRead = charsRead;
                             write(writer);
                             fileSize = fileSize + totalRead;
                   reader.close();
                   writer.close();
              System.out.println((fileSize) + " bytes read and saved as " + fileName);
         * Writes data to a new file.
         public static void write(BufferedWriter writer) {
                   for (int j = 0; j < totalRead; j++) {
                        writer.write(data[j]);
    I stripped away the directory selection and error handling to make it simpler.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

    Cadvan1123 wrote:
    I think the best choice is to use a ByteArrayOutputStreamWrong. You do not need a ByteArrayOutputStream
    and I think that it uses ASCII encodingPossible, but you can't just make that assumption. On windows for instance, there's a good likelihood it could use ANSI. And BTW, ASCII is for the most part dead, as it has been superseded by UTF-8.
    Check out t [jacobs.io.DataFetcher in TUS|http://tus.svn.sourceforge.net/viewvc/tus/tjacobs/] for a threadable and optimal/close-to-optimal solution for reading in binary files.
    Edited by: tjacobs01 on Mar 20, 2010 2:56 PM

  • My Messages comes out garbled!!! Ex. H?i¿ H?o¿w r?y?o¿u

    Messages comes out garbled on all our iPhones from 4s, 5s to 6
    Why is this happening??? Is this a conmon iPhone problem?
    we tried to fix the language to english/automatic, but it still happens.
    PLS. HELP. Thank You   

    It looks like maybe an encoding problem.  Who is your carrier?

  • Sender RFC Scenario Error:Payload Is Missing

    I am facing an issue in 'RFC2JDBC' scenario which is mentioned below:
    here our scenario is 'RFC2JDBC'.here our 'RFC' is having 2 fields in tables parameter
    i.e. empno & empname.
    the results of the 'RFC' is coming as:
    Personnel Number  Employee Name
    00000100                 Rasmiraj
    00000200                 Tanmay
    00000300                 Kanhu
    00000400                Debabrata
    00000500                shantanu
    i am triggering the 'rtfc' through a program.
    when i am triggering the 'RFC',in monitor of PI it's coming as sucessful.however in the payload one of the field value is missing i.e. employee name.(same also updating in the legacy database)
    in the payload it's appearing as:
    [  <?xml version="1.0" encoding="UTF-8" ?>
    - <rfc:ZSAM_SEND_RFC_PI xmlns:rfc="urn:sap-com:document:sap:rfc:functions">
    - <EMP_DTLS>
    - <item>
      <EMPNO>00000100</EMPNO>
      <EMPNAME />
      </item>
    - <item>
      <EMPNO>00000200</EMPNO>
      <EMPNAME />
      </item>
    - <item>
      <EMPNO>00000300</EMPNO>
      <EMPNAME />
      </item>
    - <item>
      <EMPNO>00000400</EMPNO>
      <EMPNAME>a</EMPNAME>
      </item>
    - <item>
      <EMPNO>00000500</EMPNO>
      <EMPNAME />
      </item>
      </EMP_DTLS>
      </rfc:ZSAM_SEND_RFC_PI> ]
    please,suggest.(here,we are using sender 'RFC' communication channel & an 'RFC'destination of type 'T'(with parameter registered server program,gateway host,gateway service)

    Hi rasmiraj tripathy,
    I am also facing the same problem (Sender or Payload is missing) while integrating R3 to B1 using IDOC. When I resend IDOC, it capture by B1iSN but doesn't work, it gives me error. When I look into xml document, it is found that there is no receiver payload.
    My R3 system is non-unicode and it is difficult to change it to unicode as it requires updation.
    Can you please confirm that this error is coming due to Non-Unicode, and can be resolved by setting it to Unicode.
    Note: There is no double definition of any object.

  • RFC creates no Payload

    Hi there
    I've got a flat file to rfc scenario and when I send through a file it gets processed successfully but in sxmb_moni the technical routing payload is empty. If I test the file in the mapping it creates the rfc with all it's nodes.
    Here's an example of the payload in ecc.
      <?xml version="1.0" encoding="utf-8" ?>
    - <ns2:_-POSDW_-CREATE_TRANSACTIONS_EXT xmlns:ns2="urn:sap-com:document:sap:rfc:functions">
      <IT_TRANSACTION />
      </ns2:_-POSDW_-CREATE_TRANSACTIONS_EXT>
    and there's no errors as well. and no trace of the rfc in r/3
    Any ideas on resolving this?
    Thanks,
    Jan

    Here's some screen shots to show what I mean.
    [Image 1|http://photostand.co.za/images/cp60ghxs1yi4hfrlae2v.jpg]
    [Image 2|http://photostand.co.za/images/w799lsge6xb2bob7p5.jpg]
    [Image 3|http://photostand.co.za/images/5py4ljnrx16o94iapi1.jpg]

  • Adaptive RFC 2 gives error: com/sap/ide/jco/service/internal/R3Service

    Hi,
    I've run into the following problem about NWDS. This happens as I create a Model. It appears there is a new version of the Adaptive RFC Model, which is called Adaptive RFC 2 Model.
    1. Right click on Models, and select Create.
    2. Double Click on Adaptive RFC 2 Model
    3. The error pops up. It says "An error has occurred. See error log for more details. java.lang.NoClassDefFoundError". Then if you click details you get "An error has occurred. See error log for more details. com/sap/ide/jco/service/internal/R3Service "
    If you know which log to have a look, or what this error is about please let me know urgently. Any help if much appreciated.
    Thanks,
    Ogeday Isiklar

    Hi,
    I am also getting same problem. Waiting for solution
    Regards,
    Pradeep Kumar

  • SOAP - PI- R/3 RFC  Scenario RFC parameters are not comming

    Hi Experts,
    I created one scenario as SOAP ->PI 7.1 -> R/3 RFC call.
    When I am testing this scenario Backend RFC is getting called but somehow RFC parameters are coming as blank. In XSMB_MONI it is creating two messages as successful one with correct payload.  But when I put debug code at the start of RFC , it is going to the debug code  and input parameter values are showing as empty.  Please tell me where can I check?
    Thanks,
    Siva Rama

    Hi Siva,
    Please check in the SXMB_MONI of the receiver SAP System.
    If the parameters are getting populated here then it must be passed to the RFC.
    Make sure you have imported the RFC from the receiver system itself.
    regards,
    Piyush

  • RFC Error : Commit fault: com.sap.aii.af.rfc.afcommunication

    Hi ,
    I am having a problem in a RFC to File scenario. My Sender RFC is working fine and is showing the status green in the CC Monitoring in AdapterEngine under Component Monitoring. But we are trying to trigger the data to the RFC we are getting the following error "Commit fault: com.sap.aii.af.rfc.afcommunication.R
    fcAFWException: alterna "
    The RFC connection when tested it is ok .. the connection is established.
    Please suggest.
    Regards,
    Hemanthika

    Hi,
    1. Refer to the following notes
    SAP Note 730870
    SAP Note 775765
    Also check
    RFC Error in SM58 Commit fault
    RFC Error in SM58 Commit fault com.sap.aii.af.rfc.afcommunication
    2. have a look to R/3 transaction SM58 to find your message
    Thanks
    swarup

  • Word 2007 file PDF -- Text comes through garbled!

    I'd love some help with this if possible; I can't seem to figure out why the text becomes garbled when it's converted into a PDF, but i do know that it doesn't always happen during the conversion stage. It may convert just fine, then later when i re-open the PDF it's garbled.
    I've attached an example so you all know what i'm talking about
    Please help, i can never reach a final draft if the text keeps becoming unreadable!
    -Alice

    Thanks for the suggestion Bill.
    You lost me a little bit in the middle of your explanation, but I think i found what you were talking about.
    I posted another picture of the screen i found with Control + D in the PDF.
    Also, I have found that i can edit the text with the advanced tool for text editing, but when i remove the extra spaces that were added, it ends up making the right hand side of my paragraph no longer uniform... as everything was previously aligned: justified... so i don't think i can fix it with that editor, unless there is a way to set alignment in in Acrobat?
    Thanks again!
    ~Alice

  • Why do text messages from one att phone come in garbled like %^&KYY

    my girlfriend has a blackberry storm 9550.
    all works well with only one exception.
    when her sister, who has an ATT phone, sends her text messages they appear to be all scrambled.
    no other messages from anybody else ever comes in like that....any ideas why this happens?
    this is driving both of them crazy and we dont know how to fix the problem.
    thanks
    Rock

    Also ask her if she's trying to use any strange characters in the message. Generally, that's a problem the other way (iPhone emoji often show up as gibberish or cause complete message corruption on non-iphones) but, it's worth a question.
    Best of luck.

  • When I convert a pdf to word it comes out garbled (can't use)

    how do I fix this

    Hi,
    Could you give me more information regarding the problem?
    1. Which application/service did you use for converting the PDF file?
    2. What kinds of font type and font encoding are used in the PDF file? 
        (Please check this in File > Properties > Fonts in Reader/Acrobat)
    Thank you,
    Tomoko

  • Pages printed from email come out garbled or in code--how to fix?

    When I use my printer to print from windows programs, it is fine. When I try to print from an email program, the copy is overprinted and random, as if in some sort of code.

    Probably related to this outstanding Bug. <br />
    https://bugzilla.mozilla.org/show_bug.cgi?id=454532
    ''(Please don't comment in that Bug report unless you can provide a patch to fix the problem. Vote for the Bug instead.)'' <br />
    https://bugzilla.mozilla.org/page.cgi?id=etiquette.html
    Based upon this comment - https://bugzilla.mozilla.org/show_bug.cgi?id=454532#c117 - it looks like a fix might be coming in Firefox 8.0.

  • Sometimes, when printing a received e-mail, it comes out garbled. Why?

    This only happens while in Firefox. Same e-mail prints OK when switching to Internet Explorer browser. It is not the same e-mail sender. How can I fix this problem when using Firefox?

    ''Matt [[#answer-675503|said]]''
    <blockquote>
    does it still after a reboot? what is one of those computer gremlins?
    I serious am not aware of a why, and the color has no special meaning.
    The only possibility I can think of is in the mail list, a pink color is associated with the tag later. As for changing it, it might be a synchronization from a phone or tablet that shares the account
    </blockquote>

  • Color Renders come out garbled

    Hi. Been having a very bizarre problem with Color 1.0.4. Certain files in my project have been rendering out with strange results. Here's a picture of what it looks like (original file on the left, Color render on the right): http://img709.imageshack.us/img709/3444/problemgn.png
    I encoded all of my media to Apple ProRes 422 before bringing it into Color and I'm rendering out in the same format. If anyone has any insight on this problem, I'd greatly appreciate it! Thanks!

    Looks like (although you have a consistent codec) you have different resolution settings between some clips. COLOR will often "mosaic" the image to fill in the empty spaces.
    jPo

  • Java field imported to ABAP RFC

    Hello,
    I'm using the following code in a User Defined Function within XI 3.0 and I'm having difficulty getting the correct "message id" imported into the RFC. 
    I've tried changing the data type of I_MESSAGEID.  Using this message id and the following data types I get different results: 
    I_MESSAGEID should look like this:  4989D6DBCE5B4C85E10000000A5060AC
    but when...
    I_MESSAGEID is set to CHAR(32):  Ó倃၏טℶ፝㓓
    I_MESSAGEID is set to RAW(16):  E3DF01DB7D03DB6E3ADF9E84135D34D3
    I_MESSAGEID is set to String:  ######n:ߞ##]4#
    Here is my java code:
    public String Create_ZTOR_Rec(String MsgID,String MsgDate,String MsgTime,String PONum,Container container){
    String content = "";
    MappingTrace importanttrace;
    importanttrace = container.getTrace();
    // filling the string with our RFC-XML (with values)
    String m = "<?xml version="1.0" encoding="UTF-8"?><ns0:Z_UDF_CREATE_ZTOR_REC xmlns:ns0="urn:sap-com:document:sap:rfc:functions">";
    m = m + "<I_MESSAGEID>" + MsgID + "</I_MESSAGEID>";
    m = m + "<I_EBELN>" + PONum + "</I_EBELN>";
    m = m + "<I_ERDAT>" + MsgDate + "</I_ERDAT>";
    m = m + "<I_UZEIT>" + MsgTime + "</I_UZEIT>";
    m = m + "</ns0:Z_UDF_CREATE_ZTOR_REC>";
    RfcAccessor accessor = null;
    ByteArrayOutputStream out = null;
    try
    // 1. Determine a channel (Business system, Communication channel)
    Channel channel = LookupService.getChannel("XI","GeneratedReceiverChannel_RFC");
    // 2. Get a RFC accessor for a channel.
    accessor = LookupService.getRfcAccessor(channel);
    Any Ideas how I can convert this message id in Java to import it properly?
    Thanks,
    Matt

    It is a good document and I noticed the link to Help.sap.com explained why writing to/updating a table through java mapping is not a good idea but in this case I do not have an option.
    I was unable to find anything to explain why all the other strings are processed in the RFC but the message id gets garbled.
    When I test the RFC manually it works properly.  When I attach the message id to the outgoing document it appears correctly.  So the error appears to be happening here:
    // 3. Create a xml input stream representing the function module request message.
    InputStream inputStream = new ByteArrayInputStream(m.getBytes());
    // 4. Create xml payload
    XmlPayload payload = LookupService.getXmlPayload(inputStream);
    // 5. Execute Record Create.
    Payload result = accessor.call(payload);
    InputStream in = result.getContent();
    Does anyone know how I can get the correct message id into my RFC?
    Thanks,
    Matt

Maybe you are looking for

  • Iphone 5s and "forced data useage"

    Hi all, I was an android guy for years but finally went for an iphone 5s this time around and signed up with Verizon for the new $45 plan. Unltd Text, talk, and 250MB of data or AKA "The Wifi Only Plan." I came from metro PCS and enjoyed the same dea

  • How to improve pdf export/print resolution?

    I'm getting very poor pdf resolution even at "best" setting in an export from Pages '09; it looks to be exactly the same low quality as you get with Print>pdf. Has anyone else had this problem, or even better, found a solution? I did reduce the file

  • How do I export an iPhoto slideshow from my iMac to my iBook?

    How do I export an iPhoto slideshow from my iMac to my iBook?

  • UI Add-on Server is Down

    Hello All:     I have this add-on. User use it to scan in batch iD's etc.     For 1 of the order which had a lot of batchs. In the middle of scanning it pop up a message saying UI-Add-on server is down. It didn't mention the specific add-on. And ther

  • How do i set up mobile me?

    I know where to go to set it up but it keeps telling me that im already linked to icloud.