Receiver as ABAP Proxy

Hi
I am trying to implement the following scenario:
- A SQL database is pooled and updated records and with the help of XI i have to call a BAPI in the R/3 system to create a sales order using ABAP Proxy.so before i create the Sales order i have to do a lot of validations like whether the customer code is existing,whether the material is a an existing material or not and many more.so can someone tell me how will i do all these validations before creating the sales order.
Thanks and Regards,
Jishi

Hi,
<i>Since the ABAP proxy code is written in the XI server</i> is not correct perception.
Let me clarify a few things...
ABAP Proxy code is not written in XI Server. U generate an ABAP Proxy for the ,message Interfaces developed in XI, in your target SAP system.
When u generate the Proxy for the Message Interface in SAP system, it helps you in marshalling and unmarshalling of XML data.
In the Execute synchronous/ execute asynchronous method of the generated proxy, u actually write the code/ busineess logic for ur validations.
If all validations are successful then u call the sales order BAPI.
Cheers,
siva Maranani.

Similar Messages

  • Problem receiving acknowledgement: abap proxy == file adapter

    Hi experts,
    I am developing an asynchrone interface using PI 7.0. The scenario is: SAP ==> FILE.
    In SAP I have created an abap proxy in wich I requested an acknowledgement when calling from the abap code. In PI I have created an Integration Process with a receive step, and a send step. In de send step I am asking for a transport acknowledgement.
    When I test the interface and I look in the SXMB_MONI in PI, I see the acknowledgement given back to the IP, but in the SAP backend system I don't receive anything in the abap proxy which had send the original message. In de SXMB_MONI from SAP I see a "?" Still awaiting  acknowledgement.
    Can anyone help me with this scenario? I really need an acknowledgement from the file adapter in the calling abap proxy.
    Regards, Jeroen

    You need to crate a REceiver Agreement for this sender...
    The Integration Server sends an acknowledgment message back to the sender (CENTRAL_BACK). It uses the name of the sender system for logical and technical backward routing.
    If the sender is addressed using an ABAP proxy, you must define a corresponding receiver agreement for this sender.
    http://help.sap.com/saphelp_nw04/helpdata/en/29/345d3b7c32a527e10000000a114084/content.htm
    -SM

  • Receive CSV attachment via Mail Adapter and process into ABAP proxy

    Hi,
    I have the following scenario:
    1. Receive e-mail with CSV attachment
    2. Process through Mail adapter (KeepAttachments = Yes in order to retain the CSV attachment)
    3. Receive into ABAP proxy (with CSV attachment)
    The next step is to read the attachment in the ABAP proxy and process the CSV attachment data into CRM.
    The CSV attachment contains the data I wish to process - the body of the e-mail will not contain this information.
    The problem I have is reading the attachment data in the proxy - not sure of the methods/class to call - anyone got any ideas ?
    Another question is this the best way to do this and process the CSV attachment data ?
    I know I could use the PayloadSwapBean to switch the payload to the attachment but then I am stumped with how the attachment is processed through PI 7.1 - how do you transform the CSV format payload into XML so PI will be able to process it through mapping.
    Either option is viable - an answer to either question would be great.
    1. How do you read the attachment data in an inbound ABAP proxy ?
    2. How do you transform the CSV attachment data after the PayloadSwapBean from CSV to XML ?
    Kind regards
    Colin.

    Hi Colin
    As you are not interested in processing the body of email. Swap the payload to the attachment using the PayloadSwapBean
    Change the content from CSV to XML using MessageTransformBean. Now pass this information to Proxy. You dont need to deal with attachments in proxy.
    It is not possible to read attachment in server proxy because the class and interface you create will not have data type which can refer to an attachment processing interface in ABAP.
    Thanks
    Gaurav

  • Http to Abap Proxy communication with multiple queues generation in Recevr

    Dear SDNs,
    I need some help in the following scenario, appreciate your suggestions and help .
    I am receiving the messages from sender to PI on http posting, from PI  I am sending the message to SAP system using receiver xi communication channel ( receiver is abap proxy).
    Sender will send the messages in QOS=EOIO, QUEueID=XXXt_100 etc  parameters, when large volumes cases, it is getting delayed to process it using a single queue.
    We are thinking to dynamically  generate multiple queues in PI and send the same queue ids to receiver SAP system to process all the messages quickly in SAP System also.
    Help /Clarifications needed:
    1. XI receiver communication channel in  pi  does not provide any options to generate dynamic queue id based on payload content (using dynamic configuration) and sent it to SAP.
    2. Module Tab in receiver communication channel also got disabled to add  custom adapter modules, can we add custome adapter module on xi receiver channel to generate dynamic queue id ?
    Really appreciate your immediate help and suggestions.
    Thanks.
    Suraj.

    Dear Praveen,
    Thanks lot for the immediate reply, we need to use EOIO, as the messages need to be processed in the same order we send and receive, there is no flexibility in QOS=EOIO, Appreciate if there is any other thoughts?
    Thanks In Advance.
    Suraj.

  • Performance problem in File to ABAP Proxy scenario

    Hi gurus,
        I have a scenario where the sender is sending a file and the receiver is ABAP Proxy.The file is a simple DAT file containing banking data.The file sample is as belo
    00000MM21901 PYM0901021531     
    704401020100005510000040000D0002
    704401020127147391000033500D0003
    704401020127147391000045000D0004
    704401020109341157000038800D0005
    70420!!!!10200000182174D
    704401021100006040000015158D0001
    704401021100006040000005034D0002
    7042010210000020192D
    The above file need to be split and mapped to the fields of the ABAP Proxy after doing some validations.
    Is Receiver Determination using mapping required? What is the most efficient way of splitting the file?
    Please give your replies keeping better performance of the interface in mind.What is the best way of doing the validations?
    regards
    Debansu

    Hi Satish,
        As you can see in my question above,the sender side contains a flat file(the file format is given in the question),I need to split the file into strings which can then be mapped to specific fields of the ABAP Proxy.A sample output of the xml file that is passed on to the ABAP proxy after mapping transformations is given below:
    <BATCH_TOTAL_RECORD_420>
      <BATCH_REPORT_DISTRICT>70</BATCH_REPORT_DISTRICT>
      <KEY_VALUE>420</KEY_VALUE>
      <BATCH_NUMBER>1021</BATCH_NUMBER>
      <BATCH_TOTAL>0000020192</BATCH_TOTAL>
      <FILLER_BATCH_TOTAL_SIGN>D</FILLER_BATCH_TOTAL_SIGN>
      <FILLER />
      </BATCH_TOTAL_RECORD_420>
    - <BATCH_TOTAL_RECORD_420>
      <BATCH_REPORT_DISTRICT>70</BATCH_REPORT_DISTRICT>
      <KEY_VALUE>420</KEY_VALUE>
      <BATCH_NUMBER>9999</BATCH_NUMBER>
      <BATCH_TOTAL>0000202366</BATCH_TOTAL>
      <FILLER_BATCH_TOTAL_SIGN>D</FILLER_BATCH_TOTAL_SIGN>
      <FILLER />
      </BATCH_TOTAL_RECORD_420>
    I hope now you can provide me some answers.
    Regards
    Debansu

  • ABAP Proxy with Party

    Party is using to group business systems of one partner?
    I have in one party business system which comunicate with Abap Proxy. But when I send message to SAP PI, I receive message with out Party.
    BS_ERP(abap-proxy) -> SAP PI
    Configuration looks like:
    Party
       +   Partner_1
            +   Service
                +   Business System
                    +  BS_ERP
                        +  Communaction Channel
                            +   CC_XI_Proxy_Sender
    How can abap proxy set PARTY of sender?

    My Integration Builder Configuration looks:
    Party
      + Partner_1
        + Service
          + Business System
            + BS_ERP
              + Communaction Channel
                + CC_XI_Proxy_Sender
                + CC_XI_Proxy_Receiver
    As you see business system is assigned to Party.
    If I send message from PI to BS_ERP message is:
    Sender Party: ####
    Sender Service: ####
    Receiver Party: Partner_1
    Receiver Service: BS_ERP
    If I send message BACK from BS_ERP to PI message is:
    Sender Party: _____
    Sender Service: BS_ERP
    Receiver Party: ####
    Receiver Service: ####
    Abap-proxy code is:
    DATA lv_proxy TYPE REF TO zxx_mi_somedata_outbound.(CL_PROXY_CLIENT)
    DATA lv_msg TYPE zxxmt_somedata_outbound.
    CREATE OBJECT lv_proxy.
    CALL METHOD lv_proxy->mi_somedata_outbound
      EXPORTING
        output = lv_msg.
    Where can I set that message send from party "Partner_1"?

  • ABAP Proxy Acknowledgments

    Hi,
    I have an integration process that receives Asyn ABAP Proxy messages from R3.
    After some processing the process sends back an acknowledgment to the message (positive or negative).
    I would like that messages that received an negative ack, appear in R3 Monitor with a red flag, so i can restart them.
    However, all messages appear successfully processed independently the type acknowledgment sent.
    Is there any thing i should do in ABAP when i'm calling the proxy?
    Tks.
    Jose

    I believe i have to call this method SET_ACKNOWLEDGMENT_REQUESTED , when calling the proxy.
    However i believe there is no such method in SAP R3 (620).
    If i can't get Acknowledgments working I will try another solution, like calling a proxy with message GUID and Status. The problem is that i can't find a way to change the message status in R3, and i really need it to restart errors.
    Anyone can give me a solution?

  • Abap proxy with attachments in enhanced interface determination/mapping

    Hi guys.
    We were receiving a abap proxy from ECC with a pdf attached in the header.
    This was the scenario PROXY ---> FILE
    We used the PayloadSwapBean Module in a Receiver File Adapter to get this document and put it in a FTP Server.
    Now we have to make and improvement in the scenario and we have to generate two receiver interfaces so the scenario looks like this:
    PROXY ---> FILE and JDBC.
    So we have to use an enhanced interface mapping and an enhanced interface determination.
    The problem is that with this enhanced interface determination/mapping the attached document is lost.
    Any solution?
    Thanks a lot.
    Regards.

    > The problem is that with this enhanced interface determination/mapping the attached document is lost.
    I know there was an issue in early PI 7.1 SP versions. maybe you find a bug fix for this?
    Otherwise report to SAP.

  • Does XI Adapter (ABAP Proxy)  allows multiple LogOn Languages??

    Hi ALL,
      I have a doubt like whther we can give multiple logon languages in the XI Receiver Adapter ( ABAP Proxy ).
    For example,
      I am getting data in "English" - EN  , "Russian" - RU , "Japanese" - JA etc. Can I give these all languages as "LogOn Language" while configuring the XI receiver adapter? If so how? else, is there any other option for this.
    Thanks,
    Anudeep.

    hi,
    I don't think it's possible to precise dynamically the logon lanaguage which has to be used in the receiver XI adapter (proxy).
    [Help SAP on XI adapter|http://help.sap.com/saphelp_nw70/helpdata/EN/99/115281baba404890d2561617a78409/frameset.htm]
    Maybe a solution could be in the mapping to have a rule which determines the receiver (EN, RU,JA) that should receive a message or another one, and then for each receiver to specific a unique CC. So in your case to define three CC (one for each langauge): EN + RU + JA.
    Anyway I don't really understand the reason to manage that... The interest of logon language is when we want to write a text. But in SAP you can write a Japan text even if you are log-in in English by specifying the Language Code !
    So maybe the solution of your problem, is to send to your proxy the text but also the ISO language code linked to this text, so to do what SAP does in IDoc and BAPI.
    regards
    Mickael

  • Receive mail with PDF attachment into XI and send to ABAP proxy

    Hi,
    I have a scenario where I need to receive a mail into XI that has a PDF attachment. This attachment needs to be retained as ultimately I need to send the message into CRM via an ABAP proxy and read the attachment and load against a business partner.
    However, as I am only on SP13 I do not have the parameters such "Keep Attachments" available to use.
    So I have two questions:
    1. How do I receive the mail into XI with the PDF attachment ?
    2. How do I read the attachment in an ABAP proxy ?
    Any guidance in either question would be appreciated.
    Cheers
    Colin.

    hi,
    you say that there's no keep attachment
    indicator but does the XI store the attachment or not?
    maybe it stores all attachmens
    (I work with sp16 and I don't remember how it worked with sp13)
    but try maybe it accepts attachments by default
    then it would be quite easy
    if you use then use the attachement in abap proxy
    (like I said you won't have to use any java)
    Regards,
    michal
    <a href="/people/michal.krawczyk2/blog/2005/06/28/xipi-faq-frequently-asked-questions"><b>XI / PI FAQ - Frequently Asked Questions</b></a>

  • IDOC to abap proxy- Receiver Service Cannot be converted into ALE logical

    Dear all,
    I have idoc to abap proxy  -
    R3 to SRM scenario.
    I am getting the error Receiver service cannot be converted to ale logical system.
    I have check the receiver bs SRM_BS , adapter specific attributes ... im getting the logical system ( this is not the problem)
    i am using receiver XI adapter
    with XI 3.0 as protocol
    and http destination with /sap/xi/engine?type = receiver
    i can see the data in the moni of receiver SRM system but it shows a red flag
    pls help

    Hi kiran,
    i have checked all the RFC destinations ... seems OK
    problem is in SRM moni .. sender service and sender interface are not visible.
    trace ::::
      <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Call Inbound Proxy
      -->
    - <SAP:Trace xmlns:SAP="http://sap.com/xi/XI/Message/30">
      <Trace level="1" type="B" name="CL_XMS_HTTP_HANDLER-HANDLE_REQUEST" />
    - <!--  ************************************
      -->
      <Trace level="1" type="T">XMB was called with URL /sap/xi/engine/?type=entry</Trace>
      <Trace level="1" type="T">COMMIT is done by XMB !</Trace>
      <Trace level="1" type="B" name="CL_XMS_MAIN-ENTER_XMS" />
    - <!--  ************************************
      -->
      <Trace level="1" type="B" name="CL_XMS_MAIN-SET_START_PIPELINE" />
    - <!--  ************************************
      -->
      <Trace level="1" type="B" name="SXMBCONF-SXMB_GET_XMB_USE" />
      <Trace level="1" type="B" name="CL_XMS_TROUBLESHOOT-ENTER_PLSRV" />
      <Trace level="1" type="T">****************************************************</Trace>
      <Trace level="1" type="T">* *</Trace>
      <Trace level="1" type="T">* *</Trace>
      <Trace level="1" type="T">XMB entry processing</Trace>
      <Trace level="1" type="T">system-ID = SR5</Trace>
      <Trace level="1" type="T">client = 300</Trace>
      <Trace level="1" type="T">language = E</Trace>
      <Trace level="1" type="T">user = RFCADMIN_SR5</Trace>
      <Trace level="1" type="Timestamp">2008-06-01T16:27:03Z CET</Trace>
      <Trace level="1" type="T">* *</Trace>
      <Trace level="1" type="T">* *</Trace>
      <Trace level="1" type="T">****************************************************</Trace>
      <Trace level="1" type="B" name="CL_XMS_MAIN-CALL_UC_EXECUTE" />
    - <!--  ************************************
      -->
      <Trace level="1" type="T">Message-GUID = DD2FF717DAE395F186DF001560A1C7CB</Trace>
      <Trace level="1" type="T">PLNAME = RECEIVER</Trace>
      <Trace level="1" type="T">QOS = EO</Trace>
      <Trace level="1" type="B" name="CL_XMS_MAIN-CALL_PIPELINE_ASYNC" />
    - <!--  ************************************
      -->
      <Trace level="1" type="T">Get definition of external pipeline = RECEIVER</Trace>
      <Trace level="1" type="B" name="CL_XMS_MAIN-LOOKUP_INTERNAL_PL_ID" />
      <Trace level="1" type="T">Get definition of internal pipeline = SAP_RECEIVER</Trace>
      <Trace level="1" type="T">Queue name : XBTR0003</Trace>
      <Trace level="1" type="T">Generated prefixed queue name = XBTR0003</Trace>
      <Trace level="1" type="T">Schedule message in qRFC environment</Trace>
      <Trace level="1" type="T">Setup qRFC Scheduler OK!</Trace>
      <Trace level="1" type="T">----
    </Trace>
      <Trace level="1" type="T">Going to persist message</Trace>
      <Trace level="1" type="T">NOTE: The following trace entries are always lacking</Trace>
      <Trace level="1" type="T">- Exit WRITE_MESSAGE_TO_PERSIST</Trace>
      <Trace level="1" type="T">- Exit CALL_PIPELINE_ASYNC</Trace>
      <Trace level="1" type="T">Async barrier reached. Bye-bye !</Trace>
      <Trace level="1" type="T">----
    </Trace>
      <Trace level="1" type="B" name="CL_XMS_MAIN-WRITE_MESSAGE_TO_PERSIST" />
    - <!--  ************************************
      -->
      <Trace level="1" type="T">--start sender interface action determination</Trace>
      <Trace level="1" type="T">select interface *</Trace>
      <Trace level="1" type="T">select interface namespace</Trace>
      <Trace level="1" type="T">no interface found</Trace>
      <Trace level="1" type="T">--start receiver interface action determination</Trace>
      <Trace level="1" type="T">Loop 0000000001</Trace>
      <Trace level="1" type="T">select interface SupplierPortalTradingPartner_CreateOrChange_In*</Trace>
      <Trace level="1" type="T">select interface namespace http://sap.com/xi/SRM/SupplierEnablement</Trace>
      <Trace level="1" type="T">no interface found</Trace>
      <Trace level="1" type="T">--no sender or receiver interface definition found</Trace>
      <Trace level="1" type="T">Hence set action to DEL</Trace>
      <Trace level="1" type="B" name="CL_XMS_MAIN-PERSIST_READ_MESSAGE" />
      <Trace level="1" type="T">Note: the following trace entry is written delayed (after read from persist)</Trace>
      <Trace level="1" type="B" name="SXMS_ASYNC_EXEC" />
    - <!--  ************************************
      -->
      <Trace level="1" type="T">----
    </Trace>
      <Trace level="1" type="T">Starting async processing with pipeline RECEIVER</Trace>
      <Trace level="1" type="T">system-ID = SR5</Trace>
      <Trace level="1" type="T">client = 300</Trace>
      <Trace level="1" type="T">language = E</Trace>
      <Trace level="1" type="T">user = RFCADMIN_SR5</Trace>
      <Trace level="1" type="Timestamp">2008-06-01T16:27:04Z CET</Trace>
      <Trace level="1" type="T">----
    </Trace>
      <Trace level="1" type="B" name="CL_XMS_MAIN-CALL_PIPELINE_SYNC" />
    - <!--  ************************************
      -->
      <Trace level="1" type="T">Get definition of external pipeline RECEIVER</Trace>
      <Trace level="1" type="B" name="CL_XMS_MAIN-LOOKUP_INTERNAL_PL_ID" />
      <Trace level="1" type="T">Corresponding internal pipeline SAP_RECEIVER</Trace>
      <Trace level="1" type="B" name="PLSRV_CALL_INBOUND_PROXY" />
    - <!--  ************************************
      -->
    - <Trace level="1" type="B" name="CL_XMS_MAIN-CALL_PLSRV">
      <Trace level="1" type="B" name="CL_XMS_MAIN-CALL_PLSRV_LOCAL" />
    - <!--  ************************************
      -->
      <Trace level="1" type="B" name="Inbound Framework" />
    - <!--  ************************************
      -->
    - <asx:abap xmlns:asx="http://www.sap.com/abapxml" version="1.0">
    - <asx:values>
      <CX_ERROR href="#o3314" />
      </asx:values>
    - <asx:heap xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:abap="http://www.sap.com/abapxml/types/built-in" xmlns:cls="http://www.sap.com/abapxml/classes/global" xmlns:dic="http://www.sap.com/abapxml/types/dictionary">
    - <cls:CX_SY_NO_HANDLER id="o3314">
    - <CX_ROOT>
      <TEXTID>1F09B73915F6B645E10000000A11447B</TEXTID>
      <PREVIOUS href="#o3313" />
      <KERNEL_ERRID>UNCAUGHT_EXCEPTION</KERNEL_ERRID>
    - <INTERNAL_SOURCE_POS>
      <PROGID>496</PROGID>
      <CONTID>1564</CONTID>
      </INTERNAL_SOURCE_POS>
      </CX_ROOT>
      <CX_NO_CHECK />
    - <CX_SY_NO_HANDLER>
      <CLASSNAME>CX_BBPX1_STD_MESSAGE_FAULT</CLASSNAME>
      </CX_SY_NO_HANDLER>
      </cls:CX_SY_NO_HANDLER>
    - <cls:CX_BBPX1_STD_MESSAGE_FAULT id="o3313">
    - <CX_ROOT>
      <TEXTID>65B8FEB5F43CC949B7CD662AB888ED34</TEXTID>
      <PREVIOUS />
      <KERNEL_ERRID />
    - <INTERNAL_SOURCE_POS>
      <PROGID>496</PROGID>
      <CONTID>1738</CONTID>
      </INTERNAL_SOURCE_POS>
      </CX_ROOT>
      <CX_DYNAMIC_CHECK />
      <CX_AI_APPLICATION_FAULT />
    - <CX_BBPX1_STD_MESSAGE_FAULT>
      <AUTOMATIC_RETRY />
      <CONTROLLER />
      <NO_RETRY />
    - <STANDARD>
      <CONTROLLER />
      <FAULT_TEXT>An error occured within an XI interface: Exception occurredE:BBP_BUPA_SUPPLIER:089 -Unable to determine logical system of sender; check your data Programm: CX_BBP_BD_ERROR===============CP; Include: CX_BBP_BD_ERROR===============CM002; Line: 57</FAULT_TEXT>
      <FAULT_URL />
      <FAULT_DETAIL />
      </STANDARD>
      </CX_BBPX1_STD_MESSAGE_FAULT>
      </cls:CX_BBPX1_STD_MESSAGE_FAULT>
      </asx:heap>
      </asx:abap>
      </Trace>
      <Trace level="1" type="T">System Error at Receiver... => ROLLBACK WORK</Trace>
      <Trace level="1" type="B" name="CL_XMS_MAIN-WRITE_MESSAGE_LOG_TO_PERSIST" />
      <Trace level="1" type="System_Error">Error exception return from pipeline processing!</Trace>
      <Trace level="1" type="B" name="CL_XMS_MAIN-WRITE_MESSAGE_TO_PERSIST" />
    - <!--  ************************************
      -->
      </SAP:Trace>
    fault message says the sender is not having logical sys...but my sender sys is showing logical system in adapter specific attributes
    pls help 
    points will be awarded

  • ABAP Proxy to XI scenario with no Receiver

    Hi,
    I am working on a scenario where R/3 sends a request to XI through ABAP Proxy and expects response synchronously.   I am calling a UDF Java function within a mapping to get response, so there is no receiver, per se.
    Can someone guide me how to map this scenario? 
    REQUEST_DT: Field1, Field2
    RESPONSE_DT : Resp_Field1
    Grpahical Mapping: Pass Field1, Field2 to a UDF function which populates Resp_Field1.  This Resp_Field1 is sent back to R/3 synchronously for the Request.
    I hope someone can help me.
    Thanks
    Venkat Viswanathan

    Hi ,
    check these links also...
    /people/rashmi.ramalingam2/blog/2005/06/25/an-illustration-of-java-server-proxy
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/a068cf2f-0401-0010-2aa9-f5ae4b2096f9
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/f272165e-0401-0010-b4a1-e7eb8903501
    sekhar

  • ABAP proxy client sending to XI   and Receive the data back from the DB

    Hi
    I am new to XI need a clarification on the following scenario
    I have a scenarion where ABAP Proxy (Clinet) from ECC will be sending the data to Data base server via XI,  and needs to return the values back to ECC
    ECC -
    > XI/PI -
    > Remote server  (Database)
          <-- XI/PI <--
    Can anyone give idea how can I develop this scenario.
    I am sure I would be using the Proxy BADI to send the data from ECC to XI in Asyscrounous mode,
    Thanks
    PR

    Hi,
    As you said the data will be sent asynchronously from BAPI to XI which means you will have to split up the scenario into two.
    First One -
    Sender Proxy - XI - Receiver JDBC.
    Second -
    Sender JDBC - XI - Receiver Proxy.
    You can set a flag to"1" when you insert data into table. the run a query on the database which will fetch record whose flay is set to "1" and also simultaneously rest the flag to "0" to indicate that this record is already send to SAP.You can make use of stored procedures too.
    Please award points if the reply is useful.
    Regards,
    Pragati

  • Mail Sender to Abap Proxy Receiver with Attachements

    Hi All,
    Scenario: I need to create a ticket in Solman from a mail. I intend to do the scenario as Mail sender to Abap Proxy receiver asynchronous.
    I have configured my sender mail adapter and am able to get the mails in XI. The attachements also appear in Inbound payload as MailAttachement-1, MailAttachement-2 etc. I have checked use mail packege and keep attachements in sender adapter.
    Transport Protocol: IMAP4
    Message Protocol: XIPAYLOAD
    Queries:
    1. My Inbound Data Type is the mail Package -- ximail30_xsd. Here in sxmb_moni I can see the mail attributes like from, to and the mail body in content. But How can I read the attachements in my message mapping.
    2. How can I pass these attachements to Abap Proxy ( I do not need to alter attachments only pass to proxy ). These attachements have to be attached to the Solman ticket in SOLMAN server.
    Appreciate your kind response to my above queries.
    Thanks.
    Regards,
    Siddhesh S.Tawate
    PS: I have tried using PayloadSwapBean in adapter module but still the content at source remains same.

    Hi,
    Please find below the part of code that might help you. I have given code only responsible for attachements part of the ticket.
    loop at lt_attach into l_attachment.
            count = count + 1.
            if count = 1.
              first_line = 1.
            endif.
            l_type = l_attachment->GET_CONTENT_TYPE( ).
            split l_type at '"' into l_type
                                     file_name
                                     l_name.
            l_name = file_name.
            split file_name at '.' into file_name
                                        file_type.
            l_xstring = l_attachment->GET_BINARY_DATA( ).
            strlen = xstrlen( l_xstring ).
            Compute int = ( strlen div 255 ).
            Compute rem = ( strlen mod 255 ).
            if rem <> 0.
              int = int + 1.
            endif.
            count1 = int.
            if count = 1.
              last_line = count1.
            else.
              if int = 1.
                first_line = last_line.
              else.
                last_line = first_line + count1.
              endif.
            endif.
            wa_APPX_HEADERS-APPXNO = count.
            wa_APPX_HEADERS-DESCR = l_name.
            wa_APPX_HEADERS-FILETYP = file_type.
            wa_APPX_HEADERS-FILENAM = l_name.
            wa_APPX_HEADERS-FILEFM_UL = 'BIN'.
            wa_APPX_HEADERS-FIRSTL = first_line.
            wa_APPX_HEADERS-LASTL = last_line.
            wa_APPX_HEADERS-FILELEN = strlen.
            wa_APPX_HEADERS-LAST_USR = sy-uname.
            GET TIME STAMP FIELD wa_appx_headers-TIMESTAMP.
            append wa_APPX_HEADERS to it_APPX_HEADERS.
            while count1 <> 0.
              count1 = count1 - 1.
              if count1 <> 0.
                wa_APPX_LINES_bin-LINE = l_xstring+0(255).
                shift l_xstring left by 255 places in BYTE MODE.
              ELSE.
                wa_APPX_LINES_bin-LINE = l_xstring.
              endif.
              append wa_APPX_LINES_bin to it_APPX_LINES_bin.
              clear: wa_APPX_LINES_bin, wa_APPX_LINES.
            endwhile.
            first_line = last_line + 1.
            clear: strlen, count1, file_name, file_type, l_type, int, rem, l_xstring, l_attachment.
          endloop.
    CALL FUNCTION 'BAPI_NOTIFICATION_CREATE'
            EXPORTING
              NOTIF_EXT                = wa_NOTIF_EXT
            NOTIF_CRM                = wa_NOTIF_CRM
      IBASE_DATA               =
         IMPORTING
           NUMBER                   = Refnum
           NUMB                     = Numb
           REFNUM                   = Ticket_No
           SYSID                    = SYSID
            TABLES
              NOTIF_PARTNERS           = it_NOTIF_PARTNERS
            NOTIF_NOTES              = it_NOTIF_N_EXT
              NOTIF_SAP_DATA           = it_NOTIF_SAP_DATA
            NOTIF_TEXT_HEADERS       = it_NOTIF_TEXT_HEADERS
            NOTIF_TEXT_LINES         = it_NOTIF_TEXT_LINES
            APPX_HEADERS             = it_APPX_HEADERS
            APPX_LINES               = it_APPX_LINES
            APPX_LINES_BIN           = it_APPX_LINES_BIN
             RETURN                   = RETURN
    Please observe how first and last line of attachement is calculated. That is what created problem for me initially.
    Hope this helps.
    Regards,
    Siddhesh S.Tawate

  • Sender Abap Proxy -- Receiver JDBC , catch communication channel exceptions

    Hi All,
    I have a sender abap proxy and a receiver jdbc asynchronous interface.
    Now under some circumstances when I send some junk data for an update query(which satisfies metadata requirement but wrong primary key) it shows chequered flag in both XI and r/3.
    But in communication channel it shows error.
    Queries:
    1. How do I handle this.
    2. Since this is triggered from Abap wht will be subrc when method ends in this particular case.
    3. Is there any possibility of program goin into dump?
    Regards,
    Prem

    You can catch the exception in cx_ai_system_fault.
    http://help.sap.com/saphelp_nw70/helpdata/en/75/a55c3cff8ca92be10000000a114084/content.htm
    DATA:
    lo_mes TYPE REF TO
         [Client proxy class],
    l_sys_exc TYPE REF TO
            cx_ai_system_fault,
    l_app_exc TYPE REF TO
            cx_ai_application_fault.
    CREATE OBJECT lo_mes.
    TRY.
    CALL METHOD
      lo_mes->EXECUTE_SYNCHRONOUS
        EXPORTING
          OUTPUT    = ls_request
        IMPORTING
          INPUT     = ls_response.
    CATCH cx_ai_system_fault
                INTO l_sys_exc.
    * handle system error
        EXIT.
    CATCH cx_fault_1
                INTO l_app_exc.
    * handle application error 1
    CATCH cx_fault_n
                INTO l_app_exc.
    * handle application error n
    CATCH cx_ai_application_fault
                INTO l_app_exc.
    * handle other
    * application errors
    ENDTRY.
    Thanks,
    Beena.

Maybe you are looking for