Skip to Content
avatar image
Former Member

How To determince PGRP based on Plant

Hi ,

We need to determine purchasing group based on plant in SC item details tab.

Which badi we can use for the same.?

Regards,

Nilesh

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

3 Answers

  • avatar image
    Former Member
    Aug 02, 2011 at 03:35 PM

    Try to implement the logic for BADI BBP_DOC_CHANGE_BADI / BBP_SC_CHANGE method.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Jay,

      BBP_DOC_CHANGE_BADI BADI will pass only one PGRP at a time ? right?

      And not a list of PGRPs as per custom z tables.

      Regards,

      Nilesh

  • Aug 03, 2011 at 11:17 PM

    Hello,

    Check badi BBP_PGRP_ASSIGN_BADI, which is the responsible for assigning purchasing group depending on your own criteria.

    Regards,

    Ricardo

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Thanks Jay & Ricardo ,

      But as per BBP_PGRP_ASSIGN_BADI documentation this BADI will be trigered at the end , i.e. when user clicked on order, when follow on documents are created.

      We need this shoud be triggred when user changes plant on item details tab.

      And PGRP drop down should have values only which is allowed from z table as per plant selected or changed.

      Please correct , If anything wrong.

      Thanks again.

      Nilesh

  • avatar image
    Former Member
    Sep 07, 2011 at 08:57 AM

    Problem resolved,

    We can get any item data field in badi input parameters itself.

    Just enhance structure by that field at 2 palces and 1 implicite enhancement to pass it to badi.

    Structures : BBPS_RESP_ITEM_DATA_BADI

    Add comment
    10|10000 characters needed characters exceeded

    • Hi Nilesh,

      Sorry for the late response.

      You are right, i enhanced following two structures

      1. BBPS_RESP_ITEM_DATA_BADI
      2. bbps_om_resp_item_data

      And enhanced following program to populate the values in one of this structure.

      LBBP_OMF03

      Structure BBPS_RESP_ITEM_DATA_BADI is being used by BADI BBP_PGRP_FIND.

      By adding two new fields in this structure Plant and Item GUID and populating the values in program LBBP_OMF03; i managed to set default Purchasing group based on plant.

      When user changes the plant at the line item level; the re determination of Purchasing group from plant was done in BBP_DOC_CHANGE BADI.

      Regards,
      Ashish Shah