Skip to Content

Below steps describe how to update subcontracting fields while creating purchase requisitions using bapi BAPI_PR_CREATE.

Bapi BAPI_PR_CREATE is used to create purchase requisition.But this bapi is not having any parameter to update subcontracting type. Here
we can pass values of subcontracting fields through extension table.

Pass AD_SUBCON_EBAN to extension table structure and move subcontracting type to value part.

*   Default subcontracting type to 1

    CLEAR LS_EXT_IN.

    LS_EXT_INSTRUCTURE = CL_ADSUB_CONSTANTS=>EXTIN_PR_STRUC.

    CONCATENATE ‘00010’ ‘1’ INTOLS_EXT_INVALUEPART1.

    APPEND LS_EXT_IN TO LT_EXT_IN.


Pass AD_SUBCON_EBANX to extension table structure and move X for subcontracting type to value part.

    CLEAR LS_EXT_IN.

    LS_EXT_INSTRUCTURE = CL_ADSUB_CONSTANTS=>EXTIN_PR_STRUCX.

    CONCATENATE ‘00010’ ‘X’ INTOLS_EXT_INVALUEPART1.

    APPEND LS_EXT_IN TO LT_EXT_IN.

Note that structure AD_SUBCON_EBAN and AD_SUBCON_EBANX does not exist in data dictionary.

To report this post you need to login first.

Be the first to leave a comment

You must be Logged on to comment or reply to a post.

Leave a Reply