Additional Blogs by Members
cancel
Showing results for 
Search instead for 
Did you mean: 
kevin_wilson2
Contributor

Now that we have covered the terminology of SCEM and basic configuration required to get SCM talking with ECC (Configuring an End-to-End SCEM scenario (1/3)) we will continue with describing the required configuration in ECC.

Just to summarize the scenario we are developing:

A sales order is created. It can go on a credit hold. Once removed from a credit hold it is in completed status. A delivery is created after which it is picked, packed and post goods issued. Follow PGI an invoice is generated and a Proof of Delivery is expected.

h3. ECC CONFIGURATION

Define AOT


    This is the location in the IMG of the related configuration for the AOT:

    !http://erpgenie.com/sapgenie/images/sdn2/0.JPG|alt=|src=http://erpgenie.com/sapgenie/images/sdn2/0.J...!

     

    h3. Step E5A – Add AOT to BPT
      1. Define Application Object Type
          1. Add entry for BPT (ZBPT_SORDER) 
              1. Set Update Mode => Update Task
              2. Set BPT Process Mode => Active
    h3. Step E5B - AOT (Define AOT & General Data)
      1. Define AOT – Add AOT 
          1. Select line and click “Define Application Object Types”
          1. Click “New Entries”
          1. Enter name for the AOT (ZAOT_SORDER_LINE)
          1. On the “General Data” tab enter relevant values for the AOT
              1. Sequential Number => 1 (For performance reasons, it is recommended to give the most frequently used application object types the lowest sequential numbers. The application system checks the Event Management relevance condition or function for an application object type following the order of the sequential numbers.)
              2. Event Manager => Name as setup in (E3) (SAPSCM)
              3. Object Type = BUS2032
    bq.
      1. Save

    Step E5C - AOT (Control Table)


    Main Table: represents Application Object.

    Master table: outer object needed for additional information

    Purpose of Main and Master Tables:

      1. determination of AOT: main and master tables used in conditions
      2. source for tracking IDs
          1. determination of AOT: main and master tables used in conditions
          2. source for tracking IDs

    When do I need a master table? When the info in the main table alone is not sufficient.

     

      1. On the Control Tables tab
          1. Enter the Main Object Table  (represents Application Object) (SALES_ORDER_ITEMS_NEW) and the master table (additional information) (SALES_ORDER_HEADER_NEW)
          2. Enter the Deleted Object Main Table (SALES_ORDER_ITEMS_OLD)
          3. Enter
      2. Save
    h3. Step E5D - AOT (Object ID)
      1. Define AOT – Object ID
          1. On the Object Identification tab
              1. AOID Method: Determine from field
              2. 1st Field: Main => OBJNR
      1. Save
    h3. Step E5E – AOT (Parameters / Tracking ID)
      1. Define AOT – Parameter Setup
          1. On the Parameter Setup tab
              1. TrkID Method: Determine from field
              2. Tr.Id Tab. Type => Main
              3. Tracking ID Field => OBJNR
              4. Track ID Code Set => SO_LINE
      1. Save
    h3. AOT Recap
      1. Define AOT
          1. What is left to do?
              1. Code the ABAP functions
              2. Set up the business Object extractor and link it to the AOT
              3. Set up the EM relevance function and link it to the AOT
              4. Set up all the parameter extract functions and link it to the AOT

    !http://erpgenie.com/sapgenie/images/sdn2/2.JPG|alt=|src=http://erpgenie.com/sapgenie/images/sdn2/2.J...!

     

    !http://erpgenie.com/sapgenie/images/sdn2/3.JPG|alt=|src=http://erpgenie.com/sapgenie/images/sdn2/3.J...!

    h3. Code Functions
      1. We need to Configure and Code the following ABAP functions
          1. (E6) Business Object Extractor
          2. (E7) AOT Relevance
          3. (E8) Control Data Extractor
          4. (E9) Info Data Extractor
          5. (E10) Query ID Extractor
          6. (E11) Exp Event Extractor
      1. Following the coding of these function we will link them to the AOT
    h3. Step E6A - Configure BO Extractor
      1. Configure Business Object Extractor
          1. Add new Business Object Key Extractor
              1. Enter details
                  1. Extractor => ZBO_SALESORDER
                  2. Function Module => Z_SAPTRX_XBO_SALESORDER
                  3. Description
    bq.
      1. Enter => Click Yes to create FM
          1. Copy FM => /SAPTRX/BUSOBJKEY_TEMPLATE to Z_SAPTRX_XBO_SALESORDER in Function group ZSCEM

    Step E6B - Code BO Extractor


      1. Code Business Object Extractor
          1. Double click the function module (Z_SAPTRX_XBO_SALESORDER)
    Modify the code to populate the busobj_key value accordingly
      1. Activate
      h3. Step E7A - Configure AOT Relevance
        1. Configure AOT Relevance
            1. Add new Business Object Key Extractor (Select the line “EM Relevant Functions (App. Obj. Types)” and click “New Entries”)
            2. Enter details
                1. Function => ZRA_SALESORDER
                2. Function Module Z_SAPTRX_XRA_SALESORDER
                3. Description
                4. Enter – Click yes to create the function module
      bq.
        1. “Copy” From FM: /SAPTRX/EVMGMT_RELEV_TEMPLATE, To FM: Z_SAPTRX_XRA_SALESORDER, Fn Group: ZSCEM
            1. Save and click through warning

      Step E7B - Code AOT Relevance


        1. Code AOT Relevance FM
            1. Double click the function module (Z_SAPTRX_XRA_SALESORDER)
      Modify the code to check for relevance accordingly and setting a value to e_result:
          bq.
            1. e_result = false_condition.   OR
            2. e_result = true_condition.

          bq.
            1. Activate

          Step E8A - Configure Control Parameter Extract


            1. Configure Control Parameter Extractor
                1. Add new Control Parameter Extractor (Select the line “Control Parameter Extractors” and click “New Entries”)
                    1. Enter details
                        1. Function => ZCP_SALESORDERLINE
                        2. Function Module Z_SAPTRX_XCP_SALESORDERLINE
                        3. Description
                        4. Enter – Click yes to create the function module
          bq.
            1. “Copy” From FM: /SAPTRX/CONTROL_PARAM_TEMPLATE, To FM: Z_SAPTRX_XCP_SALESORDERLINE, Fn Group: ZSCEM
                1. Save and click through warning

          Step E8B - Code Control Parameter Extract


            1. Code Control Parameter Extract FM
                1. Double click the function module (Z_SAPTRX_XCP_SALESORDERLINE)
                    1. Modify the code to append an entry into internal table  e_control_data for each required control parameter
                    2. Activate
          h3. Step E8C - Control Parameter List
            1. Enter Control Parameter List
                1. Double click the control parameter extractor as defined in (E8A) (ZCP_SALESORDERLINE)
                2. Double click “Control Parameter List”
                3. Click “New Entries”
                4. Enter the Parameter name, Description, Length and Type
                    1. Customer Number     (KUNNR)        CUSTOMER_AG
                    2. Sales Org                 (VKORG)       SALES_ORG
                    3. Creation Date           (ERDAT)        CREATE_DATE
                    4. Creation Time           (ERZET)        CREATE_TIME
                    5. Item Category           (PSTYV)        ITEM_CAT
                    6. Sales Order               (VBELN)        SALES_ORDER_NO
                    7. Sales Order Line        (POSNR)       SALES_ORDER_LINE
          bq.
            1. The name, length and type must match with the values coded in (E8B) and also those defined in SCM
            2. Save

          !http://erpgenie.com/sapgenie/images/sdn2/4.JPG|alt=|src=http://erpgenie.com/sapgenie/images/sdn2/4.J...!

          h3. Step E9A - Configure Info Parameter Extract
            1. Add new Info Parameter Extractor (Select the line “Info Parameter Extractors” and click “New Entries”)
                1. Enter details
                    1. Function => ZIP_SALESORDERLINE
                    2. Function Module Z_SAPTRX_XIP_SALESORDERLINE
                    3. Description
                    4. Enter – Click yes to create the function module
                        1. “Copy” From FM: /SAPTRX/INFO_PARAM_TEMPLATE, To FM: Z_SAPTRX_XIP_SALESORDERLINE, Fn Group: ZSCEM
          bq.
            1. Save and click through warning

          Step E9B - Code Info Parameter Extract


            1. Double click the function module (Z_SAPTRX_XIP_SALESORDERLINE)
            2. Modify the code to append an entry into internal table e_infodata for each required info parameter
            3. Activate
          h3. Step E9C – Info Parameter List
            1. Enter Info Parameter List
                1. Double click the info parameter extractor as defined in (E9A) (ZIP_SALESORDERLINE)
                2. Double click “Info Parameter List”
                3. Click “New Entries”
                    1. Enter the Parameter name, Description, Length and Type
                        1. User creating object (ERNAM)       CREATE_USER
                        2. Price                      (NETWR)       NET_PRICE
                        3. Material Number      (MATNR)       MATERIAL
                        4. Sold To Name         (NAME1)        SOLD_TO_NAME
          bq.
            1. The name, length and type must match with the values coded in (E9B) and also those defined in SCM
            2. Save

          Step E10A - Configure Query ID Extract


            1. Configure Query ID Extractor
                1. Add new Query ID Extractor (Select the line “Query ID Extractors” and click “New Entries”)
                    1. Enter details
                        1. Function => ZQI_SALESORDER
                        2. Function Module Z_SAPTRX_XQI_SALESORDER
                        3. Description
                        4. Enter – Click yes to create the function module
                        5. “Copy” From FM: /SAPTRX/QUERY_ID_TEMPLATE, To FM: Z_SAPTRX_XQI_SALESORDER, Fn Group: ZSCEM
          bq.
            1. Save and click through warning

          Step E10B - Code Query ID Extract


            1. Code Query ID Extract FM
                1. Double click the function module (Z_SAPTRX_XQI_SALESORDER )
                2. Modify the code to check for relevance accordingly
                    1. Query ID: PO_NUM (Customer PO Number)
          For each query id append to the e_infoid internal table
            1. Activate
              h3. Step E11A - Configure Expected Event Extract
                1. Configure Expected Event Extractor
                    1. Add new Expected Event Extractor (Select the line “Expected Event Extractors” and click “New Entries”)
                    2. Enter details
                        1. Function => ZEE_SALESORDER
                        2. Function Module Z_SAPTRX_XEE_SALESORDER
                        3. Description
                        4. Enter – Click yes to create the function module
                        5. “Copy” From FM: /SAPTRX/EXP_EVENT_TEMPLATE, To FM: Z_SAPTRX_XEE_SALESORDER, Fn Group: ZSCEM
                        6. Save and click through warning
              h3. Step E11B - Code Expected Event Extract
                1. Code Expected Event Extract FM
                    1. Double click the function module (Z_SAPTRX_XEE_SALESORDER)
              Modify the code to update internal table e_expeventdata with an entry for each expected event*    APPEND ls_trackingheader TO ct_trackingheader.</p><p style="border: medium none ; padding: 0pt" class="MsoNormal">** Mapping table
              3 Comments