Application Development 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: 

MARM

Former Member
0 Kudos

Hi,

I need to calculate number of pallets and cases from Qty.

Pallets = QTY * MARM-UMREN / MARM-UMREZ

Now how to calculate the Number of cases in a Pallet?

Pls help

Thanks

Ram

4 REPLIES 4

Former Member
0 Kudos

no of cases can vary from system to system...U should ask the functional owner what will be the no of cases in a pallet or how to define it.

0 Kudos

Hi,

Try something like this :

- For a pal :

      SELECT SINGLE * FROM marm WHERE matnr = itab-matnr
                                  AND meinh = 'PAL'.
      IF sy-subrc EQ 0 AND marm-umrez NE 0.
        nb_pal           = qty DIV marm-umrez.
nb_car = qty MOD marm-umrez.

- for nb of st in a KAr

      SELECT SINGLE * FROM marm WHERE matnr = itab-matnr
                                  AND meinh = 'KAR'.
      IF sy-subrc EQ 0 AND marm-umrez NE 0.
        nb_car           = Qty DIV marm-umrez.

Hope this helps

Erwan

0 Kudos

Hi

Thanks for the reply.

Pallets = TRUNC( G_QTY_BU * MARM-UMREN / MARM-UMREZ ).

G_REM = G_QTY_BU * MARM-UMREN MOD MARM-UMREZ.

The integer value will be the full pallets and the remainder(G_REM) will be used for the loose cases calculation.

You then multiply the remainder (G_REM) by the number of cases in a pallet (UMREZ) and this will give you the number of loose cases.

Pls let me know if this is correct...............

Thanks

Ram

Former Member
0 Kudos

hi

good

go through this links i hope these ll help you to solve your problem

http://help.sap.com/saphelp_nw04/helpdata/en/5f/071eed117c11d5b37d0050dadef62b/content.htm

thanks

mrutyun^