ABAP Proxy Table Parameter

Hi All,
I’m developing a File->XI->R/3 interface.
The Flat File content looks like this :
0001,0001,03.05.2003
0001,0002,03.05.2006
0001,0003,03.05.2006
I need to insert the data to an R/3 table ZTEST, and if the interface runs well I imagine that the table content will look like this :
ZTEST
Header ID     Item ID          Posting Date
0001          0001          03.05.2003
0001          0002          03.05.2006
0001          0003          03.05.2006
I’ve designed and configured all the required objects, and the data successfully received by the R/3.
The payload on R/3’s SXMB_MONI looks like this :
<?xml version=”1.0” encoding=”UTF-8” ?>
<ns0:Data1 xmlns:ns0=”http://mycomp.com/data1”>
     <Data>
          <HeaderID>0001</HeaderID>
          <ItemID>0001</ItemID>
          <PostingDate>03.05.2003</PostingDate>
     </Data>
     <Data>
          <HeaderID>0001</HeaderID>
          <ItemID>0002</ItemID>
          <PostingDate>03.05.2006</PostingDate>
     </Data>
     <Data>
          <HeaderID>0001</HeaderID>
          <ItemID>0003</ItemID>
          <PostingDate>03.05.2006</PostingDate>
     </Data>
</ns0:Data1>
But when I check my ZTEST table, it only contains the first row :
0001          0001          03.05.2003
I suppose this because my implementation on the proxy only runs once, and the parameter type is a structure.
Can we define a table parameter for ABAP Proxy instead of flat structure parameter ? So that I can loop through the
internal table and insert the row one by one.
Or is there a more common way to do this kind of interfacing ? Please advise me on this matter.
Thanks in advance,
Andy

Hi All,
Thanks for the advices......
I've tried to set the occurence before, but I guess I forgot to regenerate the proxy, that's why it's not working and I began to think that setting the occurence won't solve the problem.
After reading your answers, I set the occurence again and regenerate the proxy, all works fine now.....
Thanks for the help.
Regards,
Andy

Similar Messages

  • ABAP proxy code using internal table

    Hi XI guru's,
    Good Afternoon,
    My Scenario is ABAP Proxy to file using ztable.
    i am getting data from Sap R/3 data base as Ztable. using this Ztable i have to write ABAP Proxy code. I generated ABAP Proxy and mentioned all below.Please send me ABAP Proxy code using this details. This is very urgent. Please help me.
    ABAP proxy class:   zco_mioa_tata
    structure              :   zmt_tata
    structure                :   zdt_tata
    structure                :   zdt_tata_employee
    Table                :   zdt_tata_employee_tab
    Ztable                :   zcnu_proxy_table
    outbound structure:
    mt_tata
        employee
    thanks and regards
    sai

    Sai,
    I guess this will help you.
    1. Proxies can be a server proxy or client proxy. In our scenarios we require proxies to send or upload the data from/into SAP system.
    2. One more thing proxies can be used if your WAS &#8805; 6.2.
    3. Use Tcode SPROXY into R/3 system for proxy use.
    4. To send the data from R/3 system we use OUTBOUND PROXY. In Outbound proxy you will simply write an abap code to fetch the data from R/3 tables and then send it to XI. Below is the sample code to send the data from R/3 to XI.
    REPORT zblog_abap_proxy.
    DATA prxy TYPE REF TO zblogco_proxy_interface_ob.
    CREATE OBJECT prxy.
    DATA it TYPE zblogemp_profile_msg.
    TRY.
    it-emp_profile_msg-emp_name = 'Sarvesh'.
    it-emp_profile_msg-empno = '01212'.
    it-emp_profile_msg-DEPARTMENT_NAME = 'NetWeaver'.
    CALL METHOD prxy->execute_asynchronous
    EXPORTING
    output = it.
    commit work.
    CATCH cx_ai_system_fault .
    DATA fault TYPE REF TO cx_ai_system_fault .
    CREATE OBJECT fault.
    WRITE :/ fault->errortext.
    ENDTRY.
    Receiver adapter configurations should be done in the integration directory and the necessary sender/receiver binding should be appropriately configured. We need not do any sender adapter configurations as we are using proxies.
    5. To receive data into R/3 system we use INBOUND PROXY. In this case data is picked up by XI and send it to R/3 system via XI adapter into proxy class. Inside the inbound proxy we careate an internal table to take the data from XI and then simply by using the ABAP code we update the data inot R/3 table. BAPI can also be used inside the proxy to update the data into r/3.
    I hope this will clear few doubts in proxy.
    Just go through these links:
    http://help.sap.com/saphelp_nw04/helpdata/en/14/555f3c482a7331e10000000a114084/frameset.htm
    ABAP Server Proxies By Siva Maranani
    /people/siva.maranani/blog/2005/04/03/abap-server-proxies
    /people/sravya.talanki2/blog/2006/07/28/smarter-approach-for-coding-abap-proxies
    /people/vijaya.kumari2/blog/2006/01/26/how-do-you-activate-abap-proxies
    /people/ravikumar.allampallam/blog/2005/03/14/abap-proxies-in-xiclient-proxy
    File to R/3 via ABAP Proxy with good example
    /people/prateek.shah/blog/2005/06/14/file-to-r3-via-abap-proxy
    http://help.sap.com/saphelp_nw2004s/helpdata/en/48/d5a1fe5f317a4e8e35801ed2c88246/frameset.htm
    Generating java proxies..
    /people/prasad.ulagappan2/blog/2005/06/27/asynchronous-inbound-java-proxy
    /people/rashmi.ramalingam2/blog/2005/06/25/an-illustration-of-java-server-proxy
    Synchronous Proxies:
    Outbound Synchronous Proxy
    https://www.sdn.sap.com/irj/sdn/wiki?path=/display/profile/abap%2bproxy%2boutbound%2bprogram%2b-%2bpurchase%2border%2bsend
    Inbound Synchronous Proxy
    https://www.sdn.sap.com/irj/sdn/wiki?path=/display/profile/abap%2bproxy%2binbound%2bprogram%2b-%2bsales%2border%2bcreation
    Regards,
    Sarvesh

  • HTTP to ABAP Proxy - Problem with "Current User" parameter

    Hi experts,
    We have a HTTP to ABAP proxy sceario, where I used an HTTP Destination to connect to the proxy.
    We're trying to use the option "Current User" in that destination in order to login to ECC with the same user that in PI adapter plain.
    The user exists i both systems, PI and ECC, with the same password.
    Checking that parameter we get the following error:
    <SAP:Error><SAP:Category>XIServer</SAP:Category><SAP:Code>INTERNAL.UNAUTHORIZED</SAP:Code><SAP:P1>401 </SAP:P1><SAP:P2>Unauthorized</SAP:P2><SAP:P3>(See attachment HTMLError for details)</SAP:P3></SAP:Error>
    We think that PI is not getting the password.
    Does aybody know how to do this?
    Thanks and regards,
    LUIS B.

    Hi Chirumamilla,
    If we put user and password in SM59 (unchecking "Current User") the commuication works without problems.
    We don't want to leave a user set there, beacuse we are looking to access to PI with different users and login to ECC with the same user.
    Thanks,

  • INPUT Parameter of INBOUND ABAP PROXY

    Hello Friends,
    We have created the inbound proxy via SPROXY and we have implemented the class ZACCL_MI_VENDOR_MASTER_PROXY_I for the same. Now In the structure tab of ABAP Proxy I can see the following structure of the INPUT.
    INPUT-MT_VENDOR_MASTER_PROXY -VENDOR -VENDOR_DETAIL -RECORD_TYPE.
    Now in the record_type we are passing a single parameters C or N. i.e if i is N then new and if it C then change.
    In my class implementation i am doing the followin check.
    CASE input--MT_VENDOR_MASTER_PROXY -VENDOR -VENDOR_DETAIL -RECORD_TYPE.    WHEN 'N'.
          CALL METHOD me->create_vendor
            EXPORTING
              input          = input
            IMPORTING
              title          = title
              it_recp        = it_recp
              it_contenttext = content_text.
    WHEN 'C.
          CALL METHOD me->change_vendor
            EXPORTING
              input          = input
            IMPORTING
              title          = title
              it_recp        = it_recp
              it_contenttext = content_text.
    but I am getting following error message.
    input-MT_VENDOR_MASTER_PROXY-VENDOR-VENDOR_DETAIL-RECORD_TYPE is unknown.
    Could you please help me on this issue.
    Thanks & Regards,
    Nagaraj

    If one of  MT_VENDOR_MASTER_PROXY,VENDOR or VENDOR_DETAIL  is a table type and not a flat structure, then your statement will not work.
    Suppose if VENDOR_DETAIL is a table type, then you have to access RECORD_TYPE this way.
    * Create it_vendor_detail type table of <VENDor_DETAIL>...
    it_vendor_detail[] = input-MT_VENDOR_MASTER_PROXY-VENDOR-VENDOR_DETAIL[].
    loop at it_vendor_detail into wa_vendordetail.
    case wa_vendordetail-record_type.
    when 'N'....
    when 'C'...
    endcase.
    endloop.
    Regards,
    Ravi

  • Missing parameter in abap proxy implementing class

    we have a XI 3.0 (DR0) and a XI 7.0 (DR8) systems. We have exported a
    message interface from system DR0 and imported in DR8, then we have
    generated the abap proxy. The problem is in differences between abap
    proxy generated in XI 3.0 and the one generated in XI 7.0. The most
    sostantial difference is in parameters of implementing class where, how
    you can see from attached document, the CONTROLLER parameter is missing.Please, we need a support for this issue.

    maybe this field is not inlcuded in the version u are using (XI 7.0). but this shud not be a show stopper. u can go to the class editor and check out if the req strucutres and fields are present WRT to the I/B and O/B interface.

  • ABAP Proxy : Modification in Structure

    Hi Experts,
    I have one query in ABAP Proxy. I had one customized table type as declared
    DATA: ITAB TYPE ZABCD.
    It is having line type as ZABCD_LINE.
    This is just line type. Now I wanted to add 2 fields in same line type.
    While using SE11 whenever I am trying to change the line type of it it, i am getting status message "Change using transaction SPROXY".
    I am totally new in ABAP proxy. Can anybody will suggest me using SPROXY step by step how I can add the req. field in that line type?
    Thanks,
    Neha

    Hello Neha,
    SPROXY is the ABAP proxy generation transaction where you can create proxy class for any function module.
    This structure is linked to proxy parameter so if you want to change anything you need to go to SPROXY and then change parameter over there as per your requirement and that will change the internal used structure.
    In message interface you can select particular and double click that will take you to transaction where you can edit that object.
    Hope this helps,
    Thanks,
    Augustin.

  • How to find contents of ABAP proxy message

    we are using an ABAP proxy to send data including a document number from SAP to PI when a document is received on our SAP ERP system.
    it is possible under certain conditions that the proxy will not be processed, but the document has. I want to be able to check the messages sent to PI  to ensure that all the data has actually created a proxy message. How can I, if it is possible, find the data within the messages so I can determine if the whole process has completed OK.
    Put another way how do we know what data is in a message as listed under transaction SXMB_MONI ? The GUID in this transaction appears to relate to table SXMSPMAST but how can I find the information contained within that message so I can then link the message with the original document and then if necessary call the proxy again for that document ?
    Colin
    Edited by: Colin Heap on Oct 22, 2009 5:16 PM

    The problems I mentioned above seem to have been down to the xml messages themsleves rather than the coding found from Ravis' link however I made a few changes to the code to add more flexibility in the search parameter and also a TRY - ENDTRY to deal with the problem of abends when the SAP cannot interpret the message contents.
    please refer to the original BLOG ( Super Message Monitor for SAP XI ) by Alessandro Guarneri at the link in Ravis' post.
    I have then made the following changes. Please note that the field names used in my code are slighlty different to the original code to fit in with local coding practice however I think it will be easy for a programmer to interpret the changes
    1. Selection Screen 850 has been changed to use a SELECT-OPTION for the payload value. In Alessandros' code this is in INCLUDE ZXIMONI_RSXMB_SEL_MSG_SEL.
    * Super selection screen -------------------------------------------------- BEGIN
    TABLES: idxsndpor, idxrcvpor.
    SELECTION-SCREEN BEGIN OF SCREEN 0850 AS SUBSCREEN.
    SELECTION-SCREEN COMMENT 5(40) text-S98.
    * IDoc
    SELECTION-SCREEN BEGIN OF BLOCK idoc WITH FRAME TITLE text-s16.
    * Sender
    SELECTION-SCREEN BEGIN OF BLOCK idoc_snd WITH FRAME TITLE text-s14.
    SELECT-OPTIONS: s_snum FOR idxsndpor-idocnumber NO INTERVALS,
                    s_styp FOR idxsndpor-idoctyp    NO INTERVALS.
    SELECTION-SCREEN END OF BLOCK idoc_snd.
    * Receiver
    SELECTION-SCREEN BEGIN OF BLOCK idoc_rcv WITH FRAME TITLE text-s15.
    SELECT-OPTIONS: s_rnum FOR idxrcvpor-idocnumber NO INTERVALS,
                    s_rtyp FOR idxrcvpor-idoctyp    NO INTERVALS.
    SELECTION-SCREEN END OF BLOCK idoc_rcv.
    SELECTION-SCREEN END OF BLOCK idoc.
    * Payload
    SELECTION-SCREEN BEGIN OF BLOCK xp WITH FRAME TITLE text-s30.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (30) text-x01 FOR FIELD p_xpath.
    PARAMETERS: p_xpath TYPE text256.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (30) text-x02 FOR FIELD s_xvalue. 
    PARAMETERS: p_xvalue TYPE text256 NO-DISPLAY.                   
    SELECT-OPTIONS s_xvalue for p_xvalue.                                      
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN END OF BLOCK xp.
    SELECTION-SCREEN END OF SCREEN 0850.
    * Super selection screen -------------------------------------------------- END
    I'm having trouble entering the next piece of code for INCLUDE ZXIMONI_RSXMB_CUSTFILTERS  so will enter it in the next post.

  • Problem sending xls file in an attachment via ABAP proxy

    Hello,
    I have in tmp directory a xls file, I tranfer such file to a table, and afterwards I send in an attachment via ABAP proxy, here is the code:
         l_attachment        TYPE REF TO if_ai_attachment,
            lt_attach           TYPE prx_attach,
            l_name              TYPE string,
            lx_string           TYPE xstring,
            l_string            TYPE string,
            l_type              TYPE string,
            des                 TYPE string.
      CLASS cl_ai_factory DEFINITION LOAD.
      DATA:    BEGIN OF itab OCCURS 0,
               raw(255) TYPE x,
             END OF itab.
      DATA: l_controller TYPE REF TO if_ai_posting_controller.
      DATA: it TYPE zhcm_mt_segur_out.
      CREATE OBJECT prxy.
      OPEN DATASET orig FOR INPUT IN binary MODE.
      READ DATASET orig INTO itab-raw.
      WHILE sy-subrc = 0.
        APPEND itab.
        READ DATASET orig INTO itab-raw.
      ENDWHILE.
      CLOSE DATASET orig.
      LOOP AT itab.
        CONCATENATE lx_string itab-raw INTO lx_string in byte mode.
      ENDLOOP.
      L_NAME = 'Segur.xls'.
      L_TYPE = CL_AI_ATTACHMENT=>IF_AI_ATTACHMENT~C_MIMETYPE_EXCEL.
      TRY.
          L_ATTACHMENT =
            CL_AI_FACTORY=>CREATE_ATTACHMENT_FROM_binary(
                      P_DATA = LX_STRING
                      P_TYPE = L_TYPE
                      P_NAME = L_NAME ).
          APPEND L_ATTACHMENT TO LT_ATTACH.
          L_CONTROLLER = CL_AI_FACTORY=>CREATE_CONTROLLER( ).
          L_CONTROLLER->SET_ATTACHMENTS( LT_ATTACH ).
          CALL METHOD PRXY->EXECUTE_ASYNCHRONOUS
            EXPORTING
              CONTROLLER = L_CONTROLLER
              OUTPUT     = IT.
          COMMIT WORK.
        CATCH CX_AI_SYSTEM_FAULT .
          DATA FAULT TYPE REF TO CX_AI_SYSTEM_FAULT .
          CREATE OBJECT FAULT.
          WRITE :/ FAULT->ERRORTEXT.
      ENDTRY.
    I am using a Mail receiver channel, I receive a mail, with to attachments, one .xml and the other one .bin, I save it to my computer and I change the extension to .xls and when I try to open it, the file is not valid and can be opened after being repaired. What Im doing wrong? I would like to receive a valid xls file, what i should change?
    Thanks a lot,
    Luis

    Hi,
    yes I know, I have used the MessageTransformBean module, and the PayloadSwapBean module. But which parameter I should use for leaving only one attachement in the e-mail. I did this configuration:
    1
    localejbs/AF_Modules/MessageTransformBean
    Local Enterprise Bean
    <b>trans</b>
    2
    localejbs/AF_Modules/PayloadSwapBean
    Local Enterprise Bean
    <b>swap</b>
    3
    localejbs/AF_Modules/MessageTransformBean
    Local Enterprise Bean
    <b>trans1</b>
    4
    localejbs/sap.com/com.sap.aii.adapter.mail.app/XIMailAdapterBean
    Local Enterprise Bean
    mail
    <i><b>Module configuration</b></i>
    trans
    Transform.ContentDisposition
    inline
    swap
    swap.keyName
    payload-name
    swap
    swap.keyValue
    Segur
    trans1
    Transform.ContentDescription
    Segur
    trans1
    Transform.ContentDisposition
    attachment;filename="Segur.xls"
    trans1
    Transform.ContentType
    application/vnd.ms-excel;name="Segur.xls"
    In the e-mail I get one attachement without name .xml and another one Segur.xsl, and I want only one attachment, the last one. What I should change in my configuration??
    Best regards,
    Luis

  • Debugging of inbound ABAP proxy

    Please To show the debugging of inbound ABAP proxy, the implementation of the demo scenario is used. The demo scenario is available in any installation WebAS 6.40 or higher.

    follow this method and check debugging mode.
    Debugging of inbound proxies in WebAS 6.40 or higher
    To show the debugging of inbound ABAP proxy, the implementation of the demo scenario is used. The demo scenario is available in any installation WebAS 6.40 or higher.
    At first you have to set a break point in the ABAP code. Call transaction SPROXY. Expand the namespace http://sap.com/xi/XI/Demo/Airline, the node Message Interface (inbound) and the interface FlightBookingOrderRequest_In.
    Double click on interface II_SXIDAL_FBO_REQUEST and get the view of the proxy object properties.
    Double click on the implementing class (ABAP name) and then double click on the method name (this class has only one method).
    Now you are in the inbound proxy implementation. Set the break point on the first executable line.
    With help of the back button (F3) go back to the transaction SPROXY. Here you choose from menu Proxy -> Test Interface
    In the next pop up check the field XML Editor to maintain the payload.
    In the next screen apply suitable values or upload the XML payload of the SXMB_MONI (after mapping).
    Now the inbound proxy processing should stop at the break point.
    If the processing does not stop at the break point, there might be an error in the XML. Check at the result page for error messages.
    Debugging of inbound proxies in WebAS 6.20
    You set the break point the same way as described above.
    To start the proxy test you call the report SPRX_TEST_INBOUND.
    As parameters you enter the name of the ABAP interface and the method name of of the ABAP interface and check the parameter Edit Native XML
    In the next screen you apply suitable values or upload the XML payload of the SXMB_MONI (after mapping).
    Then you click first on save button (F11), then on back button (F3).
    Now you should see your debug session. If not, check if the XML is valid. BAPI_GOODSMVT_CREATE to post Goods Movement
    The following is an abap program making used of the BAPI function BAPI_GOODSMVT_CREATE to do Goods Receipts for Purchase Order after importing the data from an external system.
    BAPI TO Upload Inventory Data
    GMCODE Table T158G - 01 - MB01 - Goods Receipts for Purchase Order
                         02 - MB31 - Goods Receipts for Prod Order
                         03 - MB1A - Goods Issue
                         04 - MB1B - Transfer Posting
                         05 - MB1C - Enter Other Goods Receipt
                         06 - MB11
    Domain: KZBEW - Movement Indicator
         Goods movement w/o reference
    B - Goods movement for purchase order
    F - Goods movement for production order
    L - Goods movement for delivery note
    K - Goods movement for kanban requirement (WM - internal only)
    O - Subsequent adjustment of "material-provided" consumption
    W - Subsequent adjustment of proportion/product unit material
    report zbapi_goodsmovement.
    parameters: p-file like rlgrap-filename default
                                     'c:\sapdata\TEST.txt'.
    parameters: e-file like rlgrap-filename default
                                     'c:\sapdata\gdsmvterror.txt'.
    parameters: xpost like sy-datum default sy-datum.
    data: begin of gmhead.
            include structure bapi2017_gm_head_01.
    data: end of gmhead.
    data: begin of gmcode.
            include structure bapi2017_gm_code.
    data: end of gmcode.
    data: begin of mthead.
            include structure bapi2017_gm_head_ret.
    data: end of mthead.
    data: begin of itab occurs 100.
            include structure bapi2017_gm_item_create.
    data: end of itab.
    data: begin of errmsg occurs 10.
            include structure bapiret2.
    data: end of errmsg.
    data: wmenge like iseg-menge,
          errflag.
    data: begin of pcitab occurs 100,
            ext_doc(10),           "External Document Number
            mvt_type(3),           "Movement Type
            doc_date(8),           "Document Date
            post_date(8),          "Posting Date
            plant(4),              "Plant
            material(18),          "Material Number
            qty(13),               "Quantity
            recv_loc(4),           "Receiving Location
            issue_loc(4),          "Issuing Location
            pur_doc(10),           "Purchase Document No
            po_item(3),            "Purchase Document Item No
            del_no(10),            "Delivery Purchase Order Number
            del_item(3),           "Delivery Item
            prod_doc(10),          "Production Document No
            scrap_reason(10),      "Scrap Reason
            upd_sta(1),            "Update Status
          end of pcitab.
    call function 'WS_UPLOAD'
      exporting
        filename                      = p-file
        filetype                      = 'DAT'
    IMPORTING
      FILELENGTH                    =
      tables
        data_tab                      = pcitab
    EXCEPTIONS
      FILE_OPEN_ERROR               = 1
      FILE_READ_ERROR               = 2
      NO_BATCH                      = 3
      GUI_REFUSE_FILETRANSFER       = 4
      INVALID_TYPE                  = 5
      OTHERS                        = 6
    if sy-subrc <> 0.
      message id sy-msgid type sy-msgty number sy-msgno
              with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      exit.
    endif.
    gmhead-pstng_date = sy-datum.
    gmhead-doc_date = sy-datum.
    gmhead-pr_uname = sy-uname.
    gmcode-gm_code = '01'.   "01 - MB01 - Goods Receipts for Purchase Order
    loop at pcitab.
      itab-move_type  = pcitab-mvt_type.
      itab-mvt_ind    = 'B'.
      itab-plant      = pcitab-plant.
      itab-material   = pcitab-material.
      itab-entry_qnt  = pcitab-qty.
      itab-move_stloc = pcitab-recv_loc.
      itab-stge_loc   = pcitab-issue_loc.
      itab-po_number  = pcitab-pur_doc.
      itab-po_item    = pcitab-po_item.
      concatenate pcitab-del_no pcitab-del_item into itab-item_text.
      itab-move_reas  = pcitab-scrap_reason.
      append itab.
    endloop.
    loop at itab.
      write:/ itab-material, itab-plant, itab-stge_loc,
              itab-move_type, itab-entry_qnt, itab-entry_uom,
              itab-entry_uom_iso, itab-po_number, itab-po_item,
                                                  pcitab-ext_doc.
    endloop.
    call function 'BAPI_GOODSMVT_CREATE'
      exporting
        goodsmvt_header             = gmhead
        goodsmvt_code               = gmcode
      TESTRUN                     = ' '
    IMPORTING
        goodsmvt_headret            = mthead
      MATERIALDOCUMENT            =
      MATDOCUMENTYEAR             =
      tables
        goodsmvt_item               = itab
      GOODSMVT_SERIALNUMBER       =
        return                      = errmsg
    clear errflag.
    loop at errmsg.
      if errmsg-type eq 'E'.
        write:/'Error in function', errmsg-message.
        errflag = 'X'.
      else.
        write:/ errmsg-message.
      endif.
    endloop.
    if errflag is initial.
      commit work and wait.
      if sy-subrc ne 0.
        write:/ 'Error in updating'.
        exit.
      else.
        write:/ mthead-mat_doc, mthead-doc_year.
        perform upd_sta.
      endif.
    endif.
          FORM UPD_STA                                                  *
    form upd_sta.
      loop at pcitab.
        pcitab-upd_sta = 'X'.
        modify pcitab.
      endloop.
      call function 'WS_DOWNLOAD'
        exporting
          filename                      = p-file
          filetype                      = 'DAT'
    IMPORTING
      FILELENGTH                    =
        tables
          data_tab                      = pcitab
    EXCEPTIONS
      FILE_OPEN_ERROR               = 1
      FILE_READ_ERROR               = 2
      NO_BATCH                      = 3
      GUI_REFUSE_FILETRANSFER       = 4
      INVALID_TYPE                  = 5
      OTHERS                        = 6
    endform.
    *--- End of Program
    Finding the user-exits of a SAP transaction code
    Finding the user-exits of a SAP transaction code
    Enter the transaction code in which you are looking for the user-exit
    and it will list you the list of user-exits in the transaction code.
    Also a drill down is possible which will help you to branch to SMOD.
    report zuserexit no standard page heading.
    tables : tstc, tadir, modsapt, modact, trdir, tfdir, enlfdir.
             tables : tstct.
    data : jtab like tadir occurs 0 with header line.
    data : field1(30).
    data : v_devclass like tadir-devclass.
    parameters : p_tcode like tstc-tcode obligatory.
    select single * from tstc where tcode eq p_tcode.
    if sy-subrc eq 0.
       select single * from tadir where pgmid = 'R3TR'
                        and object = 'PROG'
                        and obj_name = tstc-pgmna.
       move : tadir-devclass to v_devclass.
          if sy-subrc ne 0.
             select single * from trdir where name = tstc-pgmna.
             if trdir-subc eq 'F'.
                select single * from tfdir where pname = tstc-pgmna.
                select single * from enlfdir where funcname =
                tfdir-funcname.
                select single * from tadir where pgmid = 'R3TR'
                                   and object = 'FUGR'
                                   and obj_name eq enlfdir-area.
                move : tadir-devclass to v_devclass.
              endif.
           endif.
           select * from tadir into table jtab
                         where pgmid = 'R3TR'
                           and object = 'SMOD'
                           and devclass = v_devclass.
            select single * from tstct where sprsl eq sy-langu and
                                             tcode eq p_tcode.
            format color col_positive intensified off.
            write:/(19) 'Transaction Code - ',
                 20(20) p_tcode,
                 45(50) tstct-ttext.
                        skip.
            if not jtab[] is initial.
               write:/(95) sy-uline.
               format color col_heading intensified on.
               write:/1 sy-vline,
                      2 'Exit Name',
                     21 sy-vline ,
                     22 'Description',
                     95 sy-vline.
               write:/(95) sy-uline.
               loop at jtab.
                  select single * from modsapt
                         where sprsl = sy-langu and
                                name = jtab-obj_name.
                       format color col_normal intensified off.
                       write:/1 sy-vline,
                              2 jtab-obj_name hotspot on,
                             21 sy-vline ,
                             22 modsapt-modtext,
                             95 sy-vline.
               endloop.
               write:/(95) sy-uline.
               describe table jtab.
               skip.
               format color col_total intensified on.
               write:/ 'No of Exits:' , sy-tfill.
            else.
               format color col_negative intensified on.
               write:/(95) 'No User Exit exists'.
            endif.
          else.
              format color col_negative intensified on.
              write:/(95) 'Transaction Code Does Not Exist'.
          endif.
    at line-selection.
       get cursor field field1.
       check field1(4) eq 'JTAB'.
       set parameter id 'MON' field sy-lisel+1(10).
       call transaction 'SMOD' and skip first   screen.
    *---End of Program
    u2026u2026u2026u2026u2026u2026u2026u2026u2026u2026u2026u2026u2026u2026u2026u2026u2026u2026u2026u2026u2026
    Difference Between BADI and User Exits
    Business Add-Ins are a new SAP enhancement technique based on ABAP Objects. They can be inserted into the SAP System to accommodate user requirements too specific to be included in the standard delivery. Since specific industries often require special functions, SAP allows you to predefine these points in your software. 
    As with customer exits two different views are available:
    In the definition view, an application programmer predefines exit points in a source that allow specific industry sectors, partners, and customers to attach additional software to standard SAP source code without having to modify the original object. 
    In the implementation view, the users of Business Add-Ins can customize the logic they need or use a standard logic if one is available.
    In contrast to customer exits, Business Add-Ins no longer assume a two-level infrastructure (SAP and customer solutions), but instead allow for a multi-level system landscape (SAP, partner, and customer solutions, as well as country versions, industry solutions, and the like). Definitions and implementations of Business Add-Ins can be created at each level within such a system infrastructure.
    SAP guarantees the upward compatibility of all Business Add-In interfaces. Release upgrades do not affect enhancement calls from within the standard software nor do they affect the validity of call interfaces. You do not have to register Business Add-Ins in SSCR.
    The Business Add-In enhancement technique differentiates between enhancements that can only be implemented once and enhancements that can be used actively by any number of customers at the same time. In addition, Business Add-Ins can be defined according to filter values. This allows you to control add-in implementation and make it dependent on specific criteria (on a specific Country value, for example).
    All ABAP sources, screens, GUIs, and table interfaces created using this enhancement technique are defined in a manner that allows customers to include their own enhancements in the standard. A single Business Add-In contains all of the interfaces necessary to implement a specific task.
    The actual program code is enhanced using ABAP Objects. In order to better understand the programming techniques behind the Business Add-In enhancement concept, SAP recommends reading the section on ABAP Objects.
    What is difference between badi and user-exists?
    What is difference between enhancements and user-exists? and what is the full form of BADI?
    I have another doubt in BDC IN BDC WE HAVE MSEGCALL (i did not remember the > correct name) where the error logs are stored, MSEGCALL is a table or structure.
    What is the system landscape?
    1) Difference between BADI and USER-EXIT.
        i) BADI's can be used any number of times, where as USER-EXITS can be used only one time.
           Ex:- if your assigning a USER-EXIT to a project in (CMOD), then you can not assign the same to other project.
        ii) BADI's are oops based.
    2) About 'BDCMSGCOLL' it is a structure.  Used for finding error records.
    3) Full form of BADI 'Business addins'.
    3) System land scape will be depends on your project 
        Ex:- 'Development server'>'Quality server'-> 'Production server'...... 
    List Of User Exit Related to VL01N
    I need to some restriction in fields ( Actual GI Date, T-Code:Vl01n ).
    How do you find out whcih user exits belongs to VL01n ?
    Here is the list of user exit related to VL01N :
    V02V0001   - Sales area determination for stock transport order 
    V02V0002   - User exit for storage location determination 
    V02V0003   - User exit for gate + matl staging area determination 
    V02V0004   - User Exit for Staging Area Determination (Item) 
    V50PSTAT  - Delivery: Item Status Calculation 
    V50Q0001   - Delivery Monitor: User Exits for Filling Display Fields
    V50R0001    -  Collective processing for delivery creation 
    V50R0002    - Collective processing for delivery creation 
    V50R0004    - Calculation of Stock for POs for Shipping Due Date List
    V50S0001    - User Exits for Delivery Processing 
    V53C0001    - Rough workload calculation in time per item 
    V53C0002    - W&S: RWE enhancement - shipping material type/time slot
    V53W0001   - User exits for creating picking waves 
    VMDE0001  - Shipping Interface: Error Handling - Inbound IDoc 
    VMDE0002  - Shipping Interface: Message PICKSD (Picking, Outbound) 
    VMDE0003  - Shipping Interface: Message SDPICK (Picking, Inbound) 
    VMDE0004  - Shipping Interface: Message SDPACK (Packing, Inbound)

  • Need to create ABAP proxy in ECC 6.0

    Hi All,
              I need to create Abap proxy in ECC 6.0 .Tha actual senerio is iam getting data from XI in XML format and i need to validate and update the date in the ZEE table fields respectively.i need to Modularize the class and keep the validation part separate. we should do validation framework for custom Master Data objects which can be turned On and Off. This can be used as a common framework for all master data validations.can any one guide me how to create abap proxy from staring till end ...Thanks in advance ...
    Regards,
    SRIram

    Hi,
    I got these below steps from SDNforumonly ..i do not have the link however i have the steps:
    1.check Delivered Languages service.sap.com/languages.
    2.check note 42305
    3.In transaction SMLT , Choose Classify Language (Language symbol or F5 )
    4.Supplement this language with English or German (Recommended)
    5.The language must be defined in the instance profiles so that you can log on in these languages. The relevant parameter is
    zcsa/installed_languages.
    6.Go to the language for which you want to install extra packages and choose or choose Language --> Import Package
    7.in the next screen , enter the path for language packages.
    8.start immediately or schedule it .Optionally you can use the target server to exceute this ( to avoid performance issues
    ,if you are importing in production timings, and you cna exculde this server from logon group )
    9.if any problems in importing then analyze the log and restart the import .
    10.After importing the languages, you must also import the language data in the Support Packages.Choose Language --->
    Special Actions ---> Import Support Packages
    11.Go to the language that you want to supplement and choose or Language ---> Supplement Language(this is client specific ,
    so execute for each client in your system)
    And also to the above if your system is running on non unicode you need to install the code pages (example AIX locale command) .
    Thanks.

  • Asynchro receiver ABAP-Proxy with unexpected response

    Hi Guys,
    I have an asynchro senario HTTP --> PI7.1 --> ABAP-Proxy (SAP backend ECC6.0) to update a SAP table. Once the senario runs the data in the backend table will be correcttly updated, however the SAP backend sends back a response to PI and causes a error there: NO_MAPPINGPROGRAM_FOUND. As the proxy should be asynchro the response is not expected.
    Who has idea, how to prevent the response from SAP backend back to PI? Thanks in advance!
    Regards,
    Kuan

    Hi Guys,
    the good news: my problem has been identified, the error reason is the QoS=BE, as you mentioned earlier. However I couldn't find where to setup the QoS in my scenario.
    A new advice showed me the HTTP URL configuration which I forgot to check, as it was maintained in the extern application. This HTTP-Post sends the message to our PI in my HTTP-to-ABAP Proxy and specified the parameter &QoS=BE, which is the reason of synchronous communication.
    I changed the configuration of my HTTP-Sender URL address with the new value &QoS=EO. The scenario runs now asynchronous without any error.
    More details see http://help.sap.com/saphelp_nwpi71/helpdata/en/43/64db4daf9f30b4e10000000a11466f/frameset.htm
    Thanks your support and you all are rewarded.
    Regards,
    Kuan

  • Can ABAP proxy to consume WSDL file be run as background job for every10min

    Hi all,
    I have a requirement where I need to build an interface which gatheru2019s the purchase order details and send to external third party software in their required format (as an XML file).
    So I should be the first point of contact and should trigger the interface each time a purchase order is generated.
    So I am thinking that I should develop a background job for every 10 minutes which will look for new purchase orders and gathers the information of the purchase orders and send them to external third party software in their required format.
    I have gone through all the SAP forums and e-Learning but still I have confusion in regards to how is it possible technically? Can some one guide me with some information on the same.
    I have a little bit of confusion and want to know few things.
    1)     Should I create a web service or should I consume a web service?
    2)     If I need to consume a web service, then can I write an ABAP proxy to be run in background fro evry 10 minutes? I mean can we run ABAP proxy as a batch job in the background?
    3)     Is there a difference between consuming an XML file and WSDL File?
    Any Help will be highly appreciated.
    Regards,
    Jessica.

    There are two options (as I know) to generate XML file.
    1. Use XML TRANSFORMATION to get the XML string based your TRANSFORMATION. You can input your data and get back the XML string. Download this string to a file
    Test XML generation program is:
    types: begin of ty_data,
           num   type i,
           end   of ty_data.
    DATA: itab TYPE standard table of ty_Data,
          la_data like line of itab,
          xmlstr TYPE string.
    DO 3 TIMES.
      la_data-num = sy-index.
      APPEND la_data TO itab.
    ENDDO.
    CALL TRANSFORMATION ztest_np1
      SOURCE table = itab
      RESULT XML xmlstr.
    CALL FUNCTION 'DISPLAY_XML_STRING'
      EXPORTING xml_string = xmlstr.
    My ZTEST_NP1 transformation. To create a transformation, click on the transformation in the "CALL TRANSFORMATION ztest_np1" statement. Select Simple transformation type.
    <?sap.transform simple?>
    <tt:transform xmlns:tt="http://www.sap.com/transformation-templates">
      <tt:root name="table"/>
      <tt:template>
        <table>
          <tt:loop ref=".table">
            <item>
              <tt:value ref="NUM"/>
            </item>
          </tt:loop>
        </table>
      </tt:template>
    </tt:transform>
    XML string is like:
      <?xml version="1.0" encoding="utf-8" ?>
      <table>
      <item>1</item>
      <item>2</item>
      <item>3</item>
      </table>
    To use this option, you have to create a transformation and than use it to generate the XML string.
    Check this SAP Help
    http://help.sap.com/saphelp_nw04s/helpdata/en/e3/7d4719ca581441b6841f1054ff1326/frameset.htm
    2. You can concatenate and create an XML string and download that string into a file.
    Regards,
    Naimesh Patel

  • FTP to ABAP Proxy Scenario - getting error CO_TXT_CHANNEL_PASSWORD_ERROR

    We have transported PI and EP data from development server to respective production, every thing is running fine except the abap proxy scenarios i.e. PI reads file from ftp location and calls the abap proxy but we are getting following errors:
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    <!--  Call Adapter
      -->
    <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="">
      <SAP:Category>XIServer</SAP:Category>
      <SAP:Code area="OUTBINDING">CO_TXT_CHANNEL_PASSWORD_ERROR</SAP:Code>
      <SAP:P1 />
      <SAP:P2 />
      <SAP:P3 />
      <SAP:P4 />
      <SAP:AdditionalText />
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack>Unable to read user password from communication channel of type Error when accessing the secure store (access ID = FD768D4A8772DB50E1000000AC10041E) Error while reading from the secure store: ERROR_UNKNOWN: Cannot find entry in secure store (SECSTORE,023)</SAP:Stack>
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>
    Any solution?
    Please note that I have searched and applied solutions given on SDN forums but didn't get any success. So I am looking for new suggestions.
    Regards,
    Jawed Ali

    Jawed ,
    Please test the HTTP destination of your receiver comm channel.
    Which is the RFC connection to your R3 system.
    Transaction SM59 and check the logon parameter for the connection you are using.
    Regards,

  • Error in ABAP Proxy generation?

    hai pals,
    my intention is to push the data from XI to SAPBWSEM system throgh an ABAP PROXY.
           but , here i got an error which i already mentioned in the forum, that is " no connection to integration builder(only local data visible) ".
            i went to the integration engine configuration in "SXMB_ADM" transaction in SAPBWSEM server.
            in sxmb_adm transaction ,the system ask for the "specific configuration data-catagory" like TUNNING , MONITOR,RUNTIME,TRACELOG,DEBUG and RFCADAPTER.
             im little bit confused in choosing the "catagory of configuration data".so can u pls help me in this error.
    with cheers.
    rajesh

    Did you create the RFC Destinations LCRSAPRFC and SAPSLDAPI to point your SLD ? If not do that.
    Then create RFC Dest INTEGRATION_DIRECTORY_HMI type H. Look at your XI box and make these 3 RFC Dests.
    Then use the following thread to fix your IFR_ADDRESS
    Values for table SPROXSET
    regards
    SKM

  • Build delay in messages to abap proxy without BPM / mapping

    Hi everyone,
    The abap proxy is receiving messages from PI, is having errors when receiving big loads of messages via PI.
    The proxy lock's a table causing the next message to run in error.
    The interface is not using BPM or a mapping.
    My question is:
    What are the possibilities to configure a delay in PI ? (not using a mapping or BPM process)
    The abap proxy need some time to process a message before it receives the next one.
    Br,
    Roy

    Hi,
    >>>The proxy lock's a table causing the next message to run in error.
    if you use async messages with fault messages correcty you can
    restart those abap proxies just like IDOCs - and you can schedulerestarting that too
    so this is nothing bad - just schedule the restarting and they will get processed
    Regards,
    Michal Krawczyk

Maybe you are looking for