Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

bapi

Former Member
0 Likes
1,212

Hi

BAPI_MATPHYSINV_CREATE_MULT.

What for this function module and what parameter we are going to pass and what wil b the output

8 REPLIES 8
Read only

Former Member
0 Likes
1,065

check the documentation of this BAPI.

regards

Prabhu

Read only

0 Likes
1,065

Why have so many people just copied the documententation out of SAP?! What's the point. Someone has even copied the code... The first answer telling you to look at the documentation is the correct one. If you can't go to transaction SE37 and look at the FM to find out its parameters then you need more simple help than this...

Gareth.

Read only

Former Member
0 Likes
1,065

hi,

FU BAPI_MATPHYSINV_CREATE_MULT

____________________________________________________

Short Text

Create physical inventory document

Functionality

You can use the CreateMultiple method to create one or more physical

inventory documents.

Notes

The following authorization object is checked when this method is used:

o M_ISEG_WIB plant authorization for physical inventory

Transfer

The header data of the physical inventory document is transferred with

the help of the 'head' structure. The data for the individual items is

imported in the 'Items' table. There is also a parameter called

MaxItems, which you can use to define the maximum number of items that

each physical inventory document contains.

Confirmations

Messages are returned in the Return parameter. The parameter

documentation shows the return codes and their meanings.

Further information

The method can only carry out your function if no error messages were

generated in the Return table. This is the case if the header data and

all the items were processed successfully.

Transaction control is not implemented. The calling program therefore

has to execute the Commit Work itself after this method has been

successfully called (in other words, if no errors were reported in the

Return parameter).

Parameters

HEAD

MAXITEMS

ITEMS

RETURN

Jogdand M B

Read only

Former Member
0 Likes
1,065

Hello,


 FU BAPI_MATPHYSINV_CREATE_MULT

 ____________________________________________________

 Short text

     Create Physical Inventory Document

 Functionality

     You can use the CreateMultiple method to create one or more physical
     inventory documents.

 Notes

     The following authorization object is checked when this method is used:

     o   M_ISEG_WIB  plant authorization for physical inventory

     Transfer

     The header data of the physical inventory document is transferred with
     the help of the 'head' structure. The data for the individual items is
     imported in the 'Items' table. There is also a parameter called
     MaxItems, which you can use to define the maximum number of items that
     each physical inventory document contains.

     Confirmations

     Messages are returned in the parameter return. The parameter
     documentation shows the return codes and their meanings.

 Further Information
     The method can only carry out your function if no error messages were
     generated in the "Return" table. This is the case if the header data and
     all the items were processed successfully.

     Transaction control is not implemented. The calling program therefore
     has to execute the 'Commit Work' itself after this method has been
     successfully invoked (i.e. if no errors were reported in the Return
     parameter).

 Parameter

     HEAD
     MAXITEMS
     ITEMS
     RETURN

 Exceptions

 Function group

     MB_BUS2028

Vasanth

Read only

Former Member
0 Likes
1,065

Hi Ramesh,

Please go through the Function Module Documentation. It has been given clearly about the usage of the Fm and PARAMETERS to be passed.

Best Regards,

Ram.

Read only

Former Member
0 Likes
1,065

Hello,

Check the Tcodes MI01 to MI24 which are related to Physical Inventory creation

For most of the fun modules DOCUMENTATION is maintained
from MEnu see the doc of this fun module

BAPI_MATPHYSINV_CREATE_MULT
____________________________________________________
Short Text
Create physical inventory document

Functionality
You can use the CreateMultiple method to create one or more physical inventory documents.

Notes
The following authorization object is checked when this method is used:

M_ISEG_WIB plant authorization for physical inventory
Transfer

The header data of the physical inventory document is transferred with the help of the 'head' structure. The data for the individual items is imported in the 'Items' table. There is also a parameter called MaxItems, which you can use to define the maximum number of items that each physical inventory document contains.

Confirmations

Messages are returned in the Return parameter. The parameter documentation shows the return codes and their meanings.

Further information
The method can only perform your function if no error messages were generated in the Return table. This is the case if the header data and all the items were processed successfully.

Transaction control is not implemented. The calling program therefore has to execute the Commit Work itself after this method has been successfully invoked (in other words, if no errors were reported in the Return parameter).

Parameters
HEAD
MAXITEMS
ITEMS
RETURN

Exceptions
Function Group
MB_BUS2028

Regards,

Deepu.K

Read only

Former Member
0 Likes
1,065

if at all you want to know about any FM. go to

<b>https://www.se37.com.</b>

regards,

srinivas

<b>*reward for useful answers*</b>

Read only

Former Member
0 Likes
1,065

Hi

BAPI_MATPHYSINV_CREATE_MULT--> Create Physical Inventory Document

 FUNCTION BAPI_MATPHYSINV_CREATE_MULT.
*"----------------------------------------------------------------------
*"*"Lokale Schnittstelle:
*"       IMPORTING
*"             VALUE(HEAD) LIKE  BAPI_PHYSINV_CREATE_HEAD
*"                             STRUCTURE  BAPI_PHYSINV_CREATE_HEAD
*"             VALUE(MAXITEMS) LIKE  AM07M-MAXPO OPTIONAL
*"       TABLES
*"              ITEMS STRUCTURE  BAPI_PHYSINV_CREATE_ITEMS
*"              RETURN STRUCTURE  BAPIRET2
*"----------------------------------------------------------------------

DATA: T_IISEG LIKE STANDARD TABLE OF IISEG WITH HEADER LINE.
DATA: T_EISEG LIKE STANDARD TABLE OF EISEG WITH HEADER LINE.
DATA: T_SERIALNUMBERS LIKE STANDARD TABLE OF BAPI_PHYSINV_SERIALNUMBERS
                                                       WITH HEADER LINE.
DATA: S_IIKPF LIKE IIKPF.
DATA: L_ROW   LIKE BAPIRET2-ROW.

  CLEAR:   RETURN, T_IISEG, T_EISEG, S_IIKPF.
  REFRESH: RETURN, T_IISEG, T_EISEG.
  G_ERROR = FALSE.

* map items to internal structure
  LOOP AT ITEMS.
    L_ROW = SY-TABIX.
    CLEAR T_IISEG.
    CALL FUNCTION 'MAP2I_BAPI_CREATE_ITM_TO_IISEG'
         EXPORTING
              BAPI_PHYSINV_CREATE_ITEMS = ITEMS
         CHANGING
              IISEG                     = T_IISEG
         EXCEPTIONS
              ERROR_CONVERTING_KEYS     = 1
              OTHERS                    = 2.
    IF SY-SUBRC <> 0.
      G_ERROR = TRUE.
      PERFORM SY_MSG_TO_BAPIRET2 TABLES RETURN
                                  USING L_ROW
                                        SPACE.
    ENDIF.
    APPEND T_IISEG.
  ENDLOOP.

  IF G_ERROR = FALSE.
* map head to internal structure
    CALL FUNCTION 'MAP2I_BAPI_CREATE_HD_TO_IIKPF'
         EXPORTING
              BAPI_PHYSINV_CREATE_HEAD = HEAD
         CHANGING
              IIKPF                    = S_IIKPF.

* Aufruf des FB-Inventur
    PERFORM CALL_MB_PHYSICAL_INVENTORY TABLES T_IISEG
                                              T_EISEG
                                              RETURN
                                              T_SERIALNUMBERS
                                        USING S_IIKPF
                                              C_CREATE
                                              C_DO_CHECK
                                              MAXITEMS.
    IF G_ERROR = FALSE.
      PERFORM CALL_MB_PHYSICAL_INVENTORY TABLES T_IISEG
                                                T_EISEG
                                                RETURN
                                                T_SERIALNUMBERS
                                          USING S_IIKPF
                                                C_CREATE
                                                C_DO_POST
                                                MAXITEMS.
    ENDIF.
  ENDIF.
ENDFUNCTION.

Reward all helpfull answers

Regards

Pavan