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: 

Function Module with Import parameters Material No,Batch ,Plant,StorrageLoc

former_member191434
Participant
0 Kudos

Can any one provide me the some standard function module with Import parameters Material Number, Batch , Plant, Storage Location. (I want to get Valuated Unrestricted-Use Stock)

Thanks & regards

Saifur Rahaman

2 REPLIES 2

Former Member
0 Kudos

Rather than searching for standard function module, why dont you try to create a z function module with all the import parameters and tables you need.

you can code it according to your need.

Regards,

Lalit Mohan Gupta.

Former Member
0 Kudos

Hi Saifur,

For all your requirement its available in MSEG table.

But a little tricky to calculate,,,

And I see that your requirement is to calculate Valuated Unrestricted stock...

To Calculate Opening Stock & Closing stock there are different procedures.

It just depends of\n the client requirements & usage of the material.

For example, we have different types of stocks, like, Through Pipeline, Special, Unristricted, quality, safety,

and many types of stocks.... so all these types are indicated in MSEG tabe in SOBTZ field,...

Now Comimg to your Query, You need to calculate OPENING & CLOSING STOCK.

We have a similiar standard report in MB5B Tcode..

to get the same results in your report do like this...

For valuated stock go to the MARDH, MBEWH, MCHBH tables But I Prefer MBEWH.

here in MBEWH give the month & year and you get the result in LBKUM field...

For Special stock, You need to go to another table like MKOLH,,(I forgot still 2 more) and

give the month & year inputs and you will get the result in SLABS field.

and remaining MB5B refers to its deetails lists with different Movement types,

whcih you can get clearly from MSEG Table...

Hope you can write the select Queries accordingly.

If you want to find the Stock for a particluar date, It is not available in any table as I know,

Rather you need to do calculations like this.

1. Select the stock (Menge) till date from MSEG and add all with different movement types,

Its a logic need to ask to your functional consultant,

like 101 added to stock, 601 sales, 102 rejeted, 602 added back to stock,... transfers, 261,,, like this.

But take a little time, get all these by using MKPF & MSEG tables... thats it.

-


Or----


2.Tables are MSEG , MKPF ... use Debit / Credit indicator ( Do not go woth any static Movement types )

and u have to consider all stock related table

MBEW , EBEW etc..., to get the stcok on particular date .

Please refer to Std. Tcode FBL5N for reference.

Thanks & regards,

Dileep .C