Skip to Content
0
Former Member
Jan 11, 2007 at 03:19 PM

BAPI_PO_CREATE1 : Document contains no items

1515 Views

Hi all !

I have a problem creating several purchase orders.

I try to create a purchase order from a purchase requisition.

(I don't use ME59N transaction because i have to modify some fields of purchase requisition due to customer specific rules).

To do that, i have my purchase requisition in a table. I loop at that table and call BAPI_PO_CREATE1 in that loop.

Basically my code looks like this :

LOOP at it_requisition.
  clear tables & structures of bapi.
  fill structures and tables of bapi with datas from it_requistion.
  call bapi_po_create1.
  if no error.
    commit and wait.
  else.
    rollback.
  endif.
ENDLOOP.  "it_requisition

When I have only 1 or a few orders to create, it works fine.

But when I have a huge number of orders to create, I sometimes have the following messages :

MEPO-071 : Documents contains no items

06-010 : Item [item number] does not exist

<i>Any support would be welcome.

Any good idea would be kindly appreciated.

Big reward for any solution that works :p</i>