Outbound idoc posting program Creation

Hi,
i want to create a posting program for my new idoc/segment, can anybody give some standerd posting program.

HI,
use FM: IDOC_OUTBOUND_WRITE_TO_DB
Fill int_edidd with your IDoc Data and int_EDIDC with the IDoc control.
maybe it´s useful!

Similar Messages

  • IDOC Posting Program for Vendor Master

    Hi Guys,
    Please give me the Sample Posting Program Vendor master Idoc.
    Thanks a lot in advance.
    Prabhu.r

    search with BD* in SE93
    BD14 - Outbound program for vendor master
    BD10 - Outbound Material master
    BD12 - Outbound customer master

  • Idoc (posting program)

    what is the posting program in idoc and what is the message type give me the exact definitions?

    Hi Kiran,
    The posting program in the mapping program which is used to do the mapping between the message types.
    Check out the following links for further understanding of IDocs:
    /people/ravikumar.allampallam/blog/2005/02/23/configuration-steps-required-for-posting-idocsxi
    /people/prateek.shah/blog/2005/06/08/introduction-to-idoc-xi-file-scenario-and-complete-walk-through-for-starters
    Regards,
    Archana

  • Is Reatil Problem in Outbound Idoc

    When I process POS outbound idoc wpdtax01 it will give error msg “Error in ALE service” and it have status 29, who can I resolved that problem
    can any method for reprocess POS outbound idoc
    thanks
    Amit Shivhare

    Hi Amit,
    You can reprocess POS Outbound Idoc using program RWDREPROCESS2
    Bye,
    Muralidhara

  • Performance Improve of IDOC POSTING

    CAn you give some tips for IDOC posting PROGRAM Improvement... As One of my program is taking long time while POSTING IDOC.

    Hi chinmay,
    1. data which is posted thru idoc
      finally goes thru some standard bapi,
      which ultimately posts the data.
    2. bapis are standard sap code,
       which do a lot of vlaidations
       before putting data into tables.
    3. Hence, i don't think,
      we can much upon their  improvement !
    regards,
    amit m.

  • Creation of Inbound Idoc for the Outbound Idoc in same client

    Hi,
    My requirement:
    Whenver an PO is created an Outbound IDOC is generated in system ABC with client 100.I want to pass this IDOC data to create an Inbound Idoc for Sales Order(SO) in the same client.
    It would be helpful if anyone can answer on how to Transfer the Outbound Idoc after it crosses the port.
    I found there is a field for function module in WE21,can this be used to get the requirement done.
    Please suggest.
    Regards,
    Amar

    Example of a program that create and post an inbound idoc....maybe that will help you:
    report  zzinbound_idoc.
    data: g_idoc_control_record like edi_dc40 occurs 0 with header line.
    data: g_edidd like edi_dd40 occurs 0 with header line.
    data: g_e1bpache09 like e1bpache09.
    parameter: mode type c default 'A'.
    refresh: g_idoc_control_record, g_edidd.
    clear:   g_idoc_control_record, g_edidd.
    *-Build Control Record -*
    g_idoc_control_record-mestyp  = 'ACC_DOCUMENT'.   "Message type
    g_idoc_control_record-idoctyp = 'ACC_DOCUMENT03'. "IDOC type
    g_idoc_control_record-direct  = '2'.              "Direction
    * Receiver
    case sy-sysid.
      when 'DE2'.
        g_idoc_control_record-rcvpor = 'SAPDE2'.     "Port
        g_idoc_control_record-rcvprn = 'IDOCLEGACY'. "Partner number
    endcase.
    g_idoc_control_record-rcvprt = 'LS'.             "Partner type
    g_idoc_control_record-rcvpfc = ''.               "Partner function
    * Sender
    g_idoc_control_record-sndpor = 'A000000002'.      "tRFC Port
    case sy-sysid.
      when 'DE2'.
        g_idoc_control_record-sndprn = 'IDOCLEGACY'. "Partner number
    endcase.
    g_idoc_control_record-sndprt = 'LS'.             "Partner type
    g_idoc_control_record-sndpfc = ''.               "Partner function
    g_idoc_control_record-refmes = 'Customer clearing'.
    append g_idoc_control_record.
    *-Build Idoc Segments -*
    *---E1KOMG
    clear g_edidd.
    clear g_e1bpache09.
    g_edidd-segnam               = 'E1BPACHE09'.
    g_edidd-segnum               = 1.
    move g_e1bpache09 to g_edidd-sdata.
    append g_edidd.
    *-Create idoc -*
    *-Syncronous
    if mode = 'S'.
      call function 'IDOC_INBOUND_SINGLE'
        exporting
          pi_idoc_control_rec_40              = g_idoc_control_record
    *     PI_DO_COMMIT                        = 'X'
    *   IMPORTING
    *     PE_IDOC_NUMBER                      =
    *     PE_ERROR_PRIOR_TO_APPLICATION       =
        tables
          pt_idoc_data_records_40             = g_edidd
        exceptions
          idoc_not_saved                      = 1
          others                              = 2.
      if sy-subrc <> 0.
        message id sy-msgid type sy-msgty number sy-msgno
                with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      endif.
    *-Asynchronus
    else.
      call function 'IDOC_INBOUND_ASYNCHRONOUS'
        in background task as separate unit
        tables
          idoc_control_rec_40 = g_idoc_control_record
          idoc_data_rec_40    = g_edidd.
      commit work.
    endif.
    write: / 'Well done!'.

  • Creation of Posting Programs

    Hello Everyone,
    Can anyone tell me as to how a posting program is create in ALE IDOC.As we have predefined posting program like BD10,BD11 etc.How do we create one for the custom made IDOCS.I expect a speedy response.
    Thanking you in advance.
    Regards,
    Sirisha.

    Create new segments -- WE31
    Create new IDOCs -- WE30
    Create a new message type -- WE81
    Link message type with IDOC type -- WE82
    <b>Outbound program LOGIC</b>-<b><u>Posting program</u></b> with example
    Select data from application tables
    Fill data into IDOC
    Pass IDOC to ALE layer
    (Call function MASTER_IDOC_DISTRIBUTE)
    Commit Work
    REPORT zale_example.
    Parameter for material number for getting related information
    PARAMETER : s_matnr TYPE matnr.
    Internal table for populating the control information for the IDOC
    DATA : i_edidc TYPE STANDARD TABLE OF edidc INITIAL SIZE 0
    WITH HEADER LINE.
    Internal table for the communication control record
    DATA : i_c_edidc TYPE STANDARD TABLE OF edidc INITIAL SIZE 0
    WITH HEADER LINE.
    Internal table for the populating the data record
    DATA : i_edidd TYPE STANDARD TABLE OF edidd INITIAL SIZE 0
    WITH HEADER LINE.
    Structure for the storing material related information
    DATA : struct_mara TYPE mara.
    Structure for the storing the material description
    DATA : struct_makt TYPE makt.
    Structure for the segment to populate the record in the data record
    DATA : struct_e1maram TYPE e1maram.
    DATA : struct_e1maktm TYPE e1maktm.
    Constants for the segment names.
    DATA : c_e1maram TYPE edilsegtyp.
    DATA : c_e1maktm TYPE edilsegtyp.
    START-OF-SELECTION.
    Get the application data from the tables MARA and MAKT
    PERFORM get_app_data.
    Populate the idoc.
    PERFORM pop_idoc.
    *& Form GET_APP_DATA
    Get the Application data from the MARA and MAKT
    FORM get_app_data .
    Get the Material related information from the mara.
    SELECT SINGLE *
    FROM mara
    INTO struct_mara
    WHERE matnr = s_matnr.
    Check for the sy-subrc value
    IF sy-subrc NE 0.
    Sy-subrc is not equal to zero go out of the program.
    EXIT.
    ENDIF.
    Get the material description from the makt by using matnr
    SELECT SINGLE *
    FROM makt INTO struct_makt
    WHERE matnr = s_matnr.
    Check for the sy-subrc value
    IF sy-subrc NE 0.
    Sy-subrc is not equal to zero go out of the program.
    EXIT.
    ENDIF.
    ENDFORM. " GET_APP_DATA
    *& Form MOVE_TO_E1MARAM
    populate the segment E!MARAM
    FORM move_mara_to_e1maram .
    Clear the segment
    CLEAR struct_e1maram.
    Pass the message type related information into the segment.
    MOVE: "STRUCT_MARA-MSGFN TO STRUCT_E1MARAM-MSGFN,
    struct_mara-matnr TO struct_e1maram-matnr,
    struct_mara-ersda TO struct_e1maram-ersda,
    struct_mara-ernam TO struct_e1maram-ernam,
    struct_mara-meins TO struct_e1maram-meins.
    Populate the internal table for the data record by passing the
    Segment name and application data.
    PERFORM pop_idoc_edidd USING c_e1maram struct_e1maram.
    ENDFORM. " MOVE_TO_E1MARAM
    *& Form MOVE_MAKT_TO_E1MAKTM
    Populate the segment E1MAKTM
    FORM move_makt_to_e1maktm .
    Clear the segment
    CLEAR struct_e1maktm.
    Pass the message type related information into the segment.
    MOVE : "STRUCT_MAKT-MSGFN TO STRUCT_E1MAKTM-MSGFN,
    struct_makt-spras TO struct_e1maktm-spras,
    struct_makt-maktx TO struct_e1maktm-maktx.
    Populate the internal table for the data record by passing the
    Segment name and application data.
    PERFORM pop_idoc_edidd USING c_e1maktm struct_e1maktm.
    ENDFORM. " MOVE_MAKT_TO_E1MAKTM
    *& Form POP_IDOC_EDIDD
    Populate the data record by passing the segement data
    -->P_C_E1MAKTM segment name
    -->P_STRUCT_E1MAKTM Application data
    FORM pop_idoc_edidd USING p_c_e1maktm
    p_struct_e1maktm.
    Clear the work area for the data record internaltable I_edidd
    CLEAR i_edidd.
    Move the segment name
    MOVE: p_c_e1maktm TO i_edidd-segnam,
    Pass the application data
    p_struct_e1maktm TO i_edidd-sdata.
    Append the internaltable.
    APPEND i_edidd.
    ENDFORM. " POP_IDOC_EDIDD
    *& Form POP_IDOC
    Populate the Idoc with related information
    FORM pop_idoc .
    populate the control record
    PERFORM pop_con_data.
    populate the data record by first populating the header segment
    PERFORM move_mara_to_e1maram.
    Populate the data record by populate the data segment
    PERFORM move_makt_to_e1maktm.
    call the fM master idoc distribute for creating master idoc
    PERFORM create_mat_idoc.
    ENDFORM. " POP_IDOC
    *& Form POP_CON_DATA
    Populate the control record
    FORM pop_con_data .
    Variable for the logical system name
    DATA: l_logsys TYPE edi_sndprn.
    Get the logical system name.
    CALL FUNCTION 'OWN_LOGICAL_SYSTEM_GET'
    IMPORTING
    own_logical_system = l_logsys
    EXCEPTIONS
    own_logical_system_not_defined = 1
    OTHERS = 2.
    Check for the sy-subrc value
    IF sy-subrc NE 0.
    Sy-subrc is not equal to zero go out of the program.
    EXIT.
    ENDIF.
    Clear the work area of the control record
    CLEAR i_edidc.
    Move the partener type to the control record
    MOVE : 'LS' TO i_edidc-sndprt,
    Populate the sending system name
    l_logsys TO i_edidc-sndprn,
    Populate the type system partener used
    'LS' TO i_edidc-rcvprt,
    Populate the partner number
    l_logsys TO i_edidc-rcvprn,
    Populate message type
    'MATMAS' TO i_edidc-mestyp,
    Populate the idoc type.
    'MATMAS03' TO i_edidc-idoctp.
    Append the control record data.
    APPEND i_edidc.
    ENDFORM. " POP_CON_DATA
    *& Form CREATE_MAT_IDOC
    Call the FM MASTER_IDOC_DISTRIBUTE
    FORM create_mat_idoc .
    Call the FM MASTER_IDOC_DISTRIBUTE for passing the IDOC to ALE layer.
    CALL FUNCTION 'MASTER_IDOC_DISTRIBUTE'
    EXPORTING
    master_idoc_control = i_edidc
    TABLES
    communication_idoc_control = i_c_edidc
    master_idoc_data = i_edidd
    EXCEPTIONS
    error_in_idoc_control = 1
    error_writing_idoc_status = 2
    error_in_idoc_data = 3
    sending_logical_system_unknown = 4
    OTHERS = 5.
    Check for the sy-subrc value
    IF sy-subrc NE 0.
    Sy-subrc is not equal to zero go out of the program.
    EXIT.
    ENDIF.
    ENDFORM. " CREATE_MAT_IDOC

  • What triggers idoc posting in outbound message from sap ?

    Do change or create events can be used to trigger Posting to IDOC? Have any body used idoc for outbound message sending from SAP?

    Hi Reddy,
    Posting IDoc Packets
    Two groups of function modules are used to post IDocs:
    · Function modules which process IDocs in mass. These transfer packets of IDocs for which individual IDocs are updated in the same Logical Unit of Work (LUW).
    · Function modules which process one IDoc per call.
    · INPUTTYP contains the code for posting function modules.
    To display the function module's INPUTTYP on the ALE Development screen, choose IDoc ® Inbound Processing ® Function Module® Maintain Attributes (BD51).
    INPUTTYP can contain the following values:
    · "0", for function modules which process IDocs in packets.
    "1" and "2" for function modules which process one IDoc per call:
    If you post the IDocs immediately, the SAP sending system determines the packet size. ALE inbound processing can recognize if the posting function module allows packet processing and if so, passes the IDoc packet to it. If not, the IDoc packet is split into individual IDocs.
    If IDocs are posted in the background, you can specify the size of the IDocs to be generated in the program RBDAPP01.
    If you use function modules that can process IDocs in mass, the database load is reduced.
    If you group IDocs into packets, this may also be practical for function modules that post inbound IDocs one at a time, because the ALE layer calls the function module several times in the same dialog process, thereby reducing the administrative load on the SAP system.
    If program RBDAPP01 carries out the background processing, as a guide, you should use a packet size of between 20 and 100 IDocs.
    Packet processing and parallelism complement one another. Packet processing and parallelism complement each other, although in some situations they may compete with each other. If the size of the packet is too big, this may mean that not all the available dialog processes are being used.
    Scheduling IDoc Posting  
    There are two ways of posting IDocs in ALE inbound processing:
    ·        Immediate processing:
    Upon receipt inbound IDocs are immediately released for posting. ALE inbound processing splits the IDoc packets into individual IDocs.
    ·        Background processing
    Inbound IDocs and IDoc packets are first saved in the database. IDoc packets are split into single IDocs beforehand.
    The program RBDAPP01 later releases the saved IDocs for processing. Single IDocs can be put into packets and then processed.
    Perform the following steps:
    1.       Set-up background processing (IDoc/ALE area menu):
    IDoc Interface/ALE ® Administration ® Runtime Settings ® Partner Profiles (WE20)
    Then the required setting is: In the detail screen Inbound Parameters select the option Trigger by background program.
    2.       Schedule posting (ALE customizing):
    Transaction SALE ® Set-Up System Monitoring ®
             Posting IDocs in Recipient System ®Schedule
    You can also process the IDocs manually by passing them to the posting function module.  In ALE Administration choose Monitoring ®Status Monitor (BD87), select the IDocs and then select Process.
    Regards,
    Kumar.

  • Outbound IDOC process - Using standard  or Custom Program

    Hi all,
    i'm having some doubts regarding IDOC's outbound processing.
    I'm trying to understand 2 scenarios:
    1- Trigger Standard Outbound IDOC without writting any Z program ou IDOC FM.
    It's possible to trigger a outbound idoc for exemple, whenever a sales order is created. To do this is, i suposed i don't need to write any code at all, correct?
    What i need to do is create a logical system (SALE), define Transmission protocol (WE20, in here i associate the partner, and the outbound message type? After this point is the idoc automatic triggered?
    If not, what is the correct procedure?
    2 Trigger Ountbound IDOC using Z program.
    Whats is diferent from the point 1 to this situation?
    Best regards,
    Pedro

    Kali,
    1. You can search in SE37 using IDOC_OUTPUT* for finding out corresponding function modules. It is based on message types.
    2. You can search user exit in above mentioned function module. So first get the correct populating FM & then you can search for Call Customer Function inside the code for user exit.
    3.Again ans is same as in point 1.

  • How outbound IDoc with Z segment is creating without using a program/FM?

    Hi,
    I am having an outbound IDoc with Z message type and segments.
    I need to find how this IDoc/ IDoc segment is getting created. I tried to find
    it using the segment’s where used list (in SE11- IDoc segment structure). But it
    is showing that the structure and fields are not used anywhere.
    How it is possible to create a Z segment in IDoc without
    using the corresponding structure in some program or function module?
    I have searched in google/scn for a solution, but didn’t find
    anything.
    Any one please helps me to find how this IDoc segment is
    populating?
    Regards,
    Dipin

    Hi Arthur,
    This IDoc is catering as part of a flow (Tcode IW21). I have
    set a break point in the function module ALE_IDOCS_CREATE and processed the transaction
    IW21, but the program didn’t stop in the break point, but the IDoc got created.
    Regards,
    Dipin

  • Outbound idoc creation with MIGO

    Hello,
    I need to create outbound idoc when the GR is created (MIGO).
    I created one output type (ME) with the processing program RSNASTED and form routine ALE_PROCESSING. Unfortunately, the rsnasted does not work, as I can not create message type MBGMCR in BD64 (Model). MBGMCR belongs to BAPI.
    Do you know the way how to proceed?

    yes it is BAPI. sorry for the confusion.
    Edited by: Vijay Babu Dudla on Sep 24, 2008 6:13 AM

  • Idoc inbound posting program for CRMXIF_PARTNER_SAVE_M02

    Hi Abapers,
            Im working on datamigration for Business partner using Lsmw idoc method and getting Idoc status 53 with message crmxif_partner_save function module generated successfully with BP number but some of the entries of the fields is not getting inserted into master table BUT000,can any one put a tip of light what exactly is going wrong as i have taken all necesscary steps if any one can share their views like how to trace the posting program for inbound idoc crmxif_partner_save_m02 and where exactly the data is getting inserted into database table BUT000.
    Will  appreciate all your help.

    Hello,
    at first, that would be very useful if you could say which fields/segments exactly are not transfered...
    there can be lot's of reasonsd why the fields are not inserted with 53 result status, but in general you can try several points:
    1. check if all the fields you want to transport are properly mapped
    2. you can try to debug, if indeed your mapping rules are working during convertion
    3. do you want to fill this fields in insert (to create new BP) or update mode (udate already created BP)?
    etc.
    regards,

  • There is large time differnce in Outbound IDoc's for Interest Run posting

    Hi Experts,
    When i posting Interest Run (T.code : FINT) i am executing for a range of Customers(For 4500 Customers)
    using Background Job it took nearly 3 days to execute the job in Production and i found that there is
    no Partner Profile in WE20,IDoc's went in Error.Until this its fine.
    The major problem is there are group of 100 idoc's created in no time span and it took 4 hrs time gap to create
    another idoc 100 more idoc's.
    In between these 2 bunch of idoc's another 700 idoc's created for different message types.
    Can you please let me know why there is that much time gap for the same message type for Interest Run.
    Thanks in Advance.
    Regards,
    Sudhakar Reddy Allam.

    Bhishma,
    Just clarrification for you...when you said..
    "R/3 sends an IDOC with IDOC number 100. XI (by default) submits this IDOC to the 3'rd party system with IDOC number 200 (it's own internally generated number)."
    Here Idoc number 100 is outbound idoc from R/2 where as Idoc number 200 is inbound idoc...n they are totally different idocs..not same
    I think there is work around...while mapping data from XI --> 3rd party assign / store outbound idoc in one of the unused field of inbound idoc...and while mapping back use this field to map it back...I think this will work.
    Let us know the result.
    Nilesh

  • How outbound idoc of message type WMMBXY is created? any program or FM name

    Hello Gurus,
    How outbound idoc of message type WMMBXY is created? any program or FM name??
    basic type : WMMBID01... i checked the idoc in my system, it does not have any process code....
    also, i checked the exit : EXIT_SAPLMBMB_001. It has some code but nothing to fill the segments...
    BR,
    Ks

    got the answer in : WMMBXY and WMMBID02

  • Configuring shipping point as Trigger point for posting outbound idoc

    Hello All,
    I have a requirement that on saving an Outbound Delivery(VL02N), an Outbound Idoc should be posted...but the condtion for posting the idoc should be its shipping point. I am not sure how to configure shipping point as the trigger point for the idoc.
    Please suggest.
    Thanks for your co-operation.
    Regards
    Anand

    Hi Anand,
    1. Go to transaction: NACE & select application V2 and click on output types.
    2. change display <->Change mode.
    3. select LAVA and press F6 (to copy Standard output type LAVA to ZLAV).
    4. Give ur Z name for the new custom output type.
    5. change access sequence from 0005 to 0012(shipping point).
    6. Press ENTER and click copy all.
    7. Now goto trasaction VV21, give the created output type name. ENTER
    8. Maintain entries, shipping point, customer#, Medium as '6' ...etc
    Now try VL01N with the given shipping point and check the output ZLAV has been triggered or not?
    Let's see, if we miss any configs still!
    Keep this as reference:
    http://www.erpgenie.com/sapedi/messagecontrol.htm
    Reddy

Maybe you are looking for

  • Creating context node with dynamic type

    When we are creating context node thru wizard,  Dictionary type must be filled. I'm trying to create Context node manually.Did any one tried created Context node class with Dynamic type.

  • Has anyone else seen this?

    I'm just setting up a new Mac Pro to use primarily for video editing. I'll be putting Final Cut Studio on it, but last night I just wanted to try the new iMovie and test a firewire camera. I'm not too happy with the quality I'm seeing using a Canon E

  • IPhone does not remember song or track or position in playlist or audio book

    I am hoping Apple will fix a problem with Ios7.0.x where iPhone does not remember song or track or position in playlist or audio book.  It worked fine with ios6.x

  • HP Photosmart 7525 e wakes up from sleep on its own hourly.

    My Hp Photosmart 7525 wakes up from sleep mode approx. every hour. It is set up as wireless and usb. is there some setting or update that I need to apply to fix this problem?

  • PIVOT in oracle.

    Hello there, May I know the ways to realise PIVOT in oracle. I mean to say Input stud mark1 mark2 mark3 x 100 200 300 output stud mark x 100 x 200 x 300 Thanks