Skip to Content
author's profile photo Former Member
Former Member

'BAPI_POEC_CREATE' function doesn't work with extended classic scenario

Hi everybody.

Antecedents:

We are working in an extended classic scenario.

When we create a Purchase Order via ITS in SRM, the system works ok, the PO is replicated in the ERP system.

But when we execute “BAPI_POEC_CREATE” function module in order to create a PO in SRM, no message are available in the application monitor, but the PO is not replicated in the ERP system.

Both exampled were created with exactly same data (partners, items, categories, accounts, …)

Moreover when we modify the second PO created via ITS, the systems doesn’t show any error message, we can order our PO again without error, but the PO isn’t replicate in the ERP system.

1. We executed “BAPI_POEC_GETDETAIL” function module, and there is only a difference between POs, E_PO_STATUS table.

PO created by transaction has 8 entries:

I1009 X

I1015 X

I1021

I1038

I1039 X

I1043

I1080 X

I1180

And PO created by BAPI has 5 entries:

I1015 X

I1021

I1038

I1043

I1180

2. We run “BBP_PD” transaction, and there is only a difference.

PO created by transaction mode shows:

- Message: W BBP_PD 830 Default values have been taken from Vendor PRUEBA10/purchasing organization Área Global Compras (org. compras)

And PO created by BAPI

- Message: No Messages

Could anyone help me with the problem?

Thanks in advance.

Raúl.

Add a comment
10|10000 characters needed characters exceeded

Related questions

7 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Feb 14, 2007 at 03:12 PM

    All,

    In our project we've converted Purchase Orders in our SRM system (Extended Classic Mode) and have sent those to R/3. We've only used the BAPI: BAPI_POEC_CREATE. I dont believe there is any need to use any BADIs unless you want to change any additional data in the interface to R/3.

    The Key is to ensure that the Backend fields are mapped in the Purchase Order. For example:

    BE_LOG_SYSTEM

    BE_OBJECT_TYPE

    BE_OBJECT_ID

    BE_REFOBJ_TYPE

    BE_REFOBJ

    BE_REFOBJ_ITEM

    BE_PUR_GROUP

    BE_PUR_ORG

    Regards,

    Sachin

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Sethi,

      I don't find these fields in the BAPI, can you/somebody please help me understand where to maintain these fields?

      BE_LOG_SYSTEM

      BE_OBJECT_TYPE

      BE_OBJECT_ID

      BE_REFOBJ_TYPE

      BE_REFOBJ

      BE_REFOBJ_ITEM

      BE_PUR_GROUP

      BE_PUR_ORG

      thanks,

      Venky

  • author's profile photo Former Member
    Former Member
    Posted on Feb 14, 2007 at 01:38 PM

    Hi Christophe/Raul,

    We are trying to do the same thing here i.e. post purchase orders in ECC from SRM and I tried using the BADI but the BE fields mentioned cannot be changed in the BADI - they are not in the export structures. Have you got this to work?

    Regards,

    Tony

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Feb 14, 2007 at 01:54 PM

    Hi

    What about the BADI ? Read its documentation before making any changes.

    BBP_ECS_PO_OUT_BADI		ECS: PO Transfer to Logistics Backend

    Hope this will help.

    Please reward suitable points.

    Regards

    - Atul

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Feb 14, 2007 at 02:20 PM

    Hi Raúl,

    Have you defined the corresponding SRM 'Transaction Type' and ECC 'Document Type' for the purchase order?

    You then have to specify the type within the header structure

    bapi_po_header_c-process_type

    I have previously used the function module to create SRM POs and they did replicate into the backend system. I agree with you on the differences on status messages, but the created orders were tested end to end (change, confirmation, invoiced) and did not show any other errors.

    I did not have to modify any BADI for this.

    Hope this helps!

    Cheers,

    Foh

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Mar 11, 2008 at 07:48 AM

    Hi,

    For ECS PO, we are using plug-in function module BBP_PO_INBOUND in the backend system to create/change the PO. So please use this instead.

    And if you want to call the FM from SRM for the transfer of the data to backend system, you can call the FM B46B_DPO_TRANSFER instead which eventually will also call the above FM in backend system.

    Regards.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jun 09, 2006 at 04:51 PM

    Hi Raúl,

    this is exact, BAPI_POEC_CREATE is designed to create local PO.

    If you want to replicate it to R/3, then you have to change it to an ECS PO.

    In BADI BBP_DOC_CHANGE_BADI, called at the real beginning of BBP_PD_PO_CREATE, you will have to change some data to enable the ECS scenario:

    - change header subtype to EP

    - change header log system to SRM (keep FI LS as is)

    - determine a backend purch group & org

    - complete BE fields (be_object_id, be_object_type, don't change be_log_system because it will be determined during the transfer, be_pur_org and be_pur_group will also be determined during the transfer)

    - ... and maybe other R/3 relevant fields

    Compare both PO one by one, and adapt the gaps.

    Rgds

    Christophe

    PS: please reward points for helpfull answers

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Apr 10, 2008 at 07:58 PM

    Hi there,

    If you have an SRM PO you can transfer it over to the backend using Function Module BBP_PD_PO_TRANSFER_EXEC.

    You will need to PO GUID.

    If you want to check for any backend errors, run this FM in debug mode.

    Set breakpoint at Meta_dpo_transfer,

    F5 into function CALL FUNCTION call_function

    go all the way down to

    CALL FUNCTION 'BBP_PO_INBOUND' DESTINATION lv_destination

    F6 over this and double click on lt_bapi_return[] which will have the backend errors/warnings from the backend.

    Hope this helps,

    Regards,

    Matthew

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.