Opening and Closing inventory logic from MB5B
Hi Gurus,
I have a requirement to implement the logic used in transaction MB5B for opening and closing inventory.
I went through the program and searched form IMARD, BESTAND tables as some forum posts suggest, but could not figure out the complete set of logic to calculate the opening and closing inventory.
Has any one implemented the same logic and if yes if you can share that part of code that would be of great help as i dont have time to spend on R&D for the same.
Thanks all in advance.
Best Regards,
Ram.
check this logic.
https://wiki.sdn.sap.com/wiki/pages/viewpage.action?pageId=15856
Regards
Prabhu
Similar Messages
-
Opening and closing balance logic
How to get opening and closing balances for a material and chapter-id for tarif-wise report for sales and captive consumption...
Edited by: vijetasap on Apr 13, 2009 2:25 PMHi Vijeta...
Try posting this question related to the functional domain forum of your requirement.. you might have more luck there.. -
Opening and closing Inventory report in CR
Hi Experts,
I want report like as below
ItemCode ItemDescription OpeningStk Reciept Issue ClosingStk
Selection Criteria
OpeningStk Date : 01 .01. 2013
ClosingStk Date : 31.12.2013
My working:
OINM and OITM table inner join.
select expert record for the closing stock.
But for opening stock , how to achieve it ?
Is it possible in single report to get my requirement?
Thanks in advance,
DwarakHi,
Yes. i want the Opening stock, Reciept, Issue and Closing stock as per the date.
Item Code
Description
Date
Inqty
Outqty
sum of Opening
Stock
sum of reciept
sum of reciept
Closing Stock
I0001
Item A
10-10-2013
10
0
I0001
Item A
11-11-2013
5
0
I0001
Item A
12-12-2013
0
10
I0001
Item A
03-01-2014
2
0
I0001
Item A
10-01-2014
0
1
I0001
Item A
20-02-2014
15
0
I0001
Item A
24-03-2014
0
12
5
17
13
9
how to achieve this ?
thanks in advance,
Dwarak -
Opening and closing a frame from an applet security problem
can I open a frame or a window from an applet and close the frame by using
System.exit(0) for the frame or will it throw a security problem.I am using system.exit(0) to exit the JVM.
dispose()
Releases all of the native screen resources used by this Window, its subcomponents, and all of its owned children. That is, the resources for these Components will be destroyed, any memory they consume will be returned to the OS, and they will be marked as undisplayable.
If this frame have to be close and open again don't use dispose.
there is no check whether a frame is active? what you can do is set the the new frame to null (frame = null) and also when you dispose it, this will let you know if the frame is active or not.
Noah -
Opening and closing stock from mb5b
Hi Experts
I am writing a code which will display goods reciept, issue, transfer, etc according to movement type .
I have done the coding but the problem is I am not getting the opening stock by period , I want to get sum (lbkum) sum (salk3) into some formulae column .. I want to get the sum of lbkum from mbewh joining mseg,mkpf as period -1
ie if I select 04.03.2009 , I want the sum of stock from mbewh based on period -1 . so what formale I have to write
to get the opening stock on the date selected . The date range is selected from mkpf .
I want to get stock on whatever date selected from mkpf.
SELECT SINGLE * FROM mardh
WHERE matnr = p_matnr
AND werks = p_werks
AND lfmon = p_buper
AND lfgja = p_gjahr.
Regards
Pirozyou can get all data using MC.9 report
here you can get opening and closing stock with values based on material, plant, storage location
Kindly make sure while giving period
here it will take period in month and year i.e if you want opening stock for April then you have to give it as 03.2008 to 03.2008 and closing as 04.2008 to 04.2008
Regards
Edited by: WISH on Apr 23, 2008 1:15 PM -
MB5B Report table for Open and Closing stock on date wise
Hi Frds,
I am trying get values of Open and Closing stock on date wise form the Table MARD and MBEW -Material Valuation but it does not match with MB5B reports,
Could anyone suggest correct table to fetch the values Open and Closing stock on date wise for MB5B reports.
Thanks
Mohan MHi,
Please check the below links...
Query for Opening And Closing Stock
Inventory Opening and Closing Stock
open stock and closing stock
Kuber -
Inventory opening and closing stock with value report
Hi All,
Is it possible to get details of both opening and closing stock with value of each items of last financial year (2009-10) in inventory report?
MizanHi..
you can try this query
Declare @FromDate Datetime
Declare @ToDate Datetime
set @FromDate =
(Select min(S0.Docdate) from OINM S0 where S0.Docdate >='[%0]')
set @ToDate =
(Select max(S1.Docdate) from OINM S1 where S1.Docdate <='[%1]')
select * from
SELECT T0.itemcode,
min(T0.Dscription) as 'Item Description',
min(B1.ItmsGrpNam) as 'Item Group', W1.Whscode, C1.Location,
(isnull((
Select sum(isnull(inqty,0))
from OINM O1
where O1.itemcode=T1.itemcode
and O1.Warehouse=W1.Whscode
and O1.docdate<@FromDate ),0)-
isnull((
Select sum(isnull(outqty,0))
from OINM O1
where O1.itemcode=T1.itemcode
and O1.Warehouse=W1.Whscode
and O1.docdate<@FromDate),0)
) as [Opening Stock],
isnull((
Select sum(isnull(inqty,0))
from OINM O1
where O1.itemcode=T1.itemcode
and O1.Warehouse=W1.Whscode
and O1.docdate>=@FromDate
and O1.docdate<=@ToDate and O1.inqty>0
and O1.transtype in (20,18)),0
) as [Purchase Quantity],
isnull((
Select sum(isnull(outqty,0))
from OINM O1
where O1.itemcode=T1.itemcode and O1.Warehouse=W1.Whscode
and O1.docdate>=@FromDate and O1.docdate<=@ToDate
and O1.outqty>0 and O1.transtype in (21,19)),0
) as [Purchase Return Quantity],
isnull((
Select sum(isnull(outqty,0))
from OINM O1
where O1.itemcode=T1.itemcode and O1.Warehouse=W1.Whscode
and O1.docdate>=@FromDate and O1.docdate<=@ToDate and O1.outqty>0
and O1.transtype in (13,15)),0
) as [sale Quatity],
(isnull
Select sum(isnull(inqty,0))
from OINM O1
where O1.itemcode=T1.itemcode and O1.Warehouse=W1.Whscode
and O1.docdate<=@ToDate),0
isnull((
Select sum(isnull(outqty,0))
from OINM O1
where O1.itemcode=T1.itemcode and O1.Warehouse=W1.Whscode
and O1.docdate<=@ToDate),0)
) as [Closing Stock]
FROM OINM T0
INNER JOIN OITM T1 ON T0.ItemCode = T1.ItemCode
INNER JOIN OITW T2 ON T1.ItemCode = T2.ItemCode
INNER JOIN OITB B1 ON T1.ItmsGrpCod=B1.ItmsGrpCod
INNER JOIN OWHS W1 ON T2.WhsCode = W1.WhsCode
INNER JOIN OLCT C1 ON W1.Location=C1.Code
Group by T1.itemcode, T0.Itemcode, W1.WhsCode, C1.Location
) a
where (a.[Opening Stock]
+a.[Purchase Quantity]
+ a.[Purchase Return Quantity]
+a.[sale Quatity]+a.[Closing Stock]
) !=0
Regards,
Bhavank -
Opening and closing balance difference is showing from 2010 to 2011 F.year
Dear All,
Opening and closing balance difference is showing for Main Cash(Cash in h)
End of fiscal year 2010 closing Balance 85,451,909.70
Opening Balance 2011 is showing as 85,450,909.70
Rs 1000 difference is coming.
Please suggest if any Note is there?Hi,
Somes after year end for audit / management adjustment entries postings done with previous year.
Execute N no of times Balance carry forward T.Code: FAGLGVTR until you get your closing balances & opening balances are the same. it is not harm to execute again & again.
up to 4.7EE for balance transfer you can use T.Code:F.16 from ECC 5 / 6 use tcode for balance transfer FAGLGVTR
Regards,
Viswa
Edited by: viswanatha s on Nov 4, 2011 12:54 PM -
MacBook Pro is operating more and more slowly in opening and closing, opening and closing programs and accessing and closing from mobile broadband. Is there a solution to this problem?
Did you try rebooting?
-
Hi sapgurus
I need a report with similar to MB5B at particular posting date with opening and closing balances but I am unable to download the report to excel the data with MB5B tranasaction.Is there any similar transaction with same output values which can be easily transported to excel from Sap.
ThanxHi,
I tested in ECC6.0 and i could able to do so, you try as mentioned below.
In the output screen of MB5B, goto menu details > click on list > select save > select file > select spreadsheet. Here you can save tthe output in excel format.
Regards,
Prabu -
Reg:Opening and Closing Stock For Plant
Hi All,
i want to calculate the opening stock and closing stock for plant wise for the given Posting Period Date.
Am having the opening balance and closing balance for all months but i need it as month wise.
considering this example,
the date is from 15.01.2010 to 15.03.2010 and for one plant
considering this example,
am having the opening stock from as 15.01.2010 to 15.03.2010 as 10,000 and the closing stock as 15,000.
but i need in month wise like below,
from 15.01.2010 to 31.01.2010 what is the opening stock and closing stock?
from 01.02.2010 to 28.02.2010 what is the opening stock and closing stock?
from 01.03.2010 to 15.03.2010 what is the opening stock and closing stock?
this is purely based on plant wise and not material wise?
could anybody say clearly how can i acheive this scenario?
i have referred MB5b,mc.9 transaction programs but still confused how to go with plant wise for a particular period?
Thanks & Regards,
Suresh
Edited by: suresh suresh on Mar 24, 2010 10:15 AMHi,
Refer to link below:
http://help.sap.com/erp2005_ehp_04/helpdata/EN/c1/3766e7449a11d188fe0000e8322f96/frameset.htm
Regards,
Venkat. -
Opening and closing stock report
Hi,
i have to develop a report in abap of stock (Opening and closing stock) with each material, plant, business area & monthly date wise. I got some fields from mseg like material number, plant, business area but i didnt get fileds like opening stock, purchase, consumption & closing stock
in report fileds should be like
material number
plant
business area
posting date
opening stock
purchase
consumption
closing stock
kinldy help <removed by moderator>
Moderator message: Welcome to SCN!
Moderator message: please search for available information, ask a functional consultant near you.
[Rules of engagement|http://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement]
[Asking Good Questions in the Forums to get Good Answers|Asking Good Questions in the SCN Discussion Spaces will help you get Good Answers]
Edited by: Thomas Zloch on Nov 21, 2011 3:35 PMYes umesh from external 99% of your stock from mvt 101, 501 is very rare case & 561 is not from external source it is initial stock updation which will be done only once when you are going live & later 561 mvt will be normally blocked for use.
You can also sort in MB5B more than one movement type click on multiple selection (that is on yellow arrow icon) & in single value tab enter mvt 101 below that 501.
This will give you report for mvt types 101 & 501 in this way you can also sort reports for more than one mvt type.
Regards
Rang
Message was edited by:
Ranganath Mysore -
Functional Specification For Opening And closing stock On Particular Date
Dear Gurus,
I am creating report for opening and closing stock on particular date in which batch and storage location should also be included. I want to know the tables and fields for the same.I have searched the forum and got report on month basis but I want this report on posting day basis.kindly suggest tables and fields. Thanks in AdvanceDear sir,
There are many other colums that client wants to add which are not present in MB5B transaction.columns which client wants to add are as follows...
Material Number
Material Description
Material Type
Material Group
External material Group
Movement Type
Plant
Storage Location
Customer Number
Customer Name
Vendor Number
Vendor Name
Posting Date Receipt Doc. Number
Issue Doc. Number
Reference Issue Document Number
Opening Stock Quanity
Material Receipt Quantity
Material Issue Quantity
Material Closing Stock Quantity
Value Of Closing Stock
And for this I want tables and logic for the same. kindly provide the solution for the same. -
Query for Opening And Closing Stock
Hi Experts...
I need a report for Opening and Closing stocks and Goods Receipt and Goods Issue for Raw Materials and Finished Goods and Consumbles ..instead of going for different reports for each we need a combined report which can display for all Raw Materials, Finished Goods and Consumbles and we need it for a specific date range Material type(Raw MAterials,Finished Goods, Consumbales)
and below is the format i needed.
RAW MATERIALS /FINISHED GOODS/CONSUMBALES
Opening Stock Closing Stock Goods Receipt Goods Issue
Qty Value Qty Value Qty Value Qty Value
Item Name
Regards,
Vamsi.Hi Guys.
I need an Inventory stock report with Item name, Opening Stock,Goods issue Quantity,Goods Received ,Item Price,Location ,(Closing Stock)Total Value.
We need the input by Date Range and Item Group and Location(if Possible) Below is the Code i used to run the report.
Pls Update the Query...
Declare @FromDate Datetime
Declare @ToDate Datetime
Declare @Group nvarchar(10)
Declare @Whse nvarchar(10)
Set @FromDate = (Select min(S0.Docdate) from dbo.OINM S0 where S0.Docdate >='[%0]')
Set @ToDate = (Select max(S1.Docdate) from dbo.OINM s1 where S1.Docdate <='[%1]')
Set @Group = (Select Max(s2.ItmsGrpCod) from dbo.OITB S2 Where S2.ItmsGrpNam = '[%2]')
Set @Whse = (Select Max(s3.Warehouse) from dbo.OINM S3 Where S3.Warehouse = '[%3]')
Select @Whse as 'Warehouse', a.Itemcode, max(a.Dscription), sum(a.[Opening Balance]) as [Opening Balance], sum(a.[IN]) as [IN], sum(a.OUT) as OUT,max(a.Price) as 'Price', ((sum(a.[Opening Balance]) + sum(a.[IN])) - Sum(a.OUT)) as Closing from dbo.OITM I1
Left JOIN (Select N1.Warehouse, N1.Itemcode, N1.Dscription,N1.Price, (sum(N1.inqty)-sum(n1.outqty)) as [Opening Balance], 0 as [IN], 0 as OUT
From dbo.OINM N1
Where N1.DocDate < @FromDate and N1.Warehouse = @Whse
Group By N1.Warehouse,N1.ItemCode,N1.Dscription,N1.Price
Union All
select N1.Warehouse, N1.Itemcode, N1.Dscription,N1.price, 0 as [Opening Balance], sum(N1.inqty) as [IN], 0 as OUT From dbo.OINM N1 Where N1.DocDate >= @FromDate and N1.DocDate <= @ToDate and N1.Inqty >0 and N1.Warehouse = @Whse Group By N1.Warehouse,N1.ItemCode,N1.Dscription,N1.price
Union All
select N1.Warehouse, N1.Itemcode, N1.Dscription,N1.price, 0 as [Opening Balance], 0 as [IN], sum(N1.outqty) as OUT From dbo.OINM N1 Where N1.DocDate >= @FromDate and N1.DocDate <=@ToDate and N1.OutQty > 0 and N1.Warehouse = @Whse Group By N1.Warehouse,N1.ItemCode,N1.Dscription,N1.price) a ON a.ItemCode=I1.ItemCode
where I1.ItmsGrpCod = @Group
Group By a.Itemcode
Order By a.Itemcode
Regards,
Vamsi. -
Dear all
iam trying to generate the opening and closing stock report for normal materials and sub contract material , so what logic i have to uss to generate the report
1) opening stock its movement type
2)recived movement types
3) issues movement type
4) closing stock
standard t-code mb5b
i want to make new report,
waiting for replyHave you tried with MB51 / MB52 ??
Lakshmipathi
Maybe you are looking for
-
Why are animated GIFs still broken?
https://discussions.apple.com/thread/1229922 <-- this 'nuff said, this has been a problem ever since Preview lost its ability to animate GIFs. It may be a WebKit problem (i.e. yeah, Apple, just go ahead and let yourself off the hook...right), but reg
-
How to Narrow the Design of an Entire Page
Hi, I have been working on this problem for a while and still do not have an answer. I use Dreamweaver CS5.5. I am new at writing html code. My question is: How do I set the width to a more narrowed setting of my entire design that is currently
-
Help ! TC changes on subclip export
Hello: I import all of my DV footage into FCP 5.1.2 by using the 'Capture Now' option (DV NTSC Easy Setup) to capture the entire tape and then use the 'Detect DV Start/Stop' function to mark the master clip, then make subclips from that. The problem
-
Question regarding Home Sharing in iOS 4.3
Does one have to enable sharing inside iTunes as well as turning on Home Sharing? Some of the how to's I have read say you need to check the boxes in iTunes Sharing while others just say to turn on Home Sharing in iTunes and in iPad iPod settings.Tha
-
Is this a hoax or spam or real
[6/28/2012 11:12:37 AM] *** Call from SYSTEM NOTICE - URGENT ONLINE REPAIR ***