How to calculate total stock quantity in cube

Dear Master
    I want to verify the data between BI report and cube whether correct or not.My report name is stock summary. It's giving report for Total quantity stock (0TOTALSTCK) for paricular date. This KF(0TOTALSTCK) inflow is 0RECTOTSTCK and outflow is 0ISSTOTSTCK. Somebody telling to get the Total quantity stock (0TOTALSTCK) value, I have to use following formula 0RECVS_VAL (Value Received into Valuated Stock) - 0ISSVS_VAL (Value issued from valuated stock). Please advice me which formula should I use to get the total stock quantity?.
Thanks a lot in advance
Raja

Please let met understand better, you have the following keyfigures:
- Receipts (Cumulative)
- Issues (Cumulative)
- Difference (Cumulative) populated during URules = Receipts - Issues (any routine with elaborated calculation behind?
- Stock (non-cumulative InFlow = Receipts, OutFlow = Issues)...
Is this correct?
Olivier.

Similar Messages

  • How to calculate totals in Blocked ALV Report

    Hi All,
    Can any body tell how to calculate totals & sub totals in
    Blocked ALV Report[Blocked List].
    Thanks in advance
    Thanks & Regards,
    Rayeezuddin.

    read this it might help
    Sums                                                       
    15. No_sumchoice(1) TYPE c : This parameter allows the choice for summing up
    Only by fieldcatalog.
    Value set: SPACE, 'X'
    'X' = fields which are to be summed, passed by the calling program (FIELDCAT-DO_SUM = 'X'). The user should not be able to change this value interactively.
    16. No_totalline(1) TYPE c : Removes the option of having totals after sub-totals.
    Value set: SPACE, 'X'
    'X' = no total record is to be output. Subtotals can still be calculated and output. The fields in the subtotals are flagged DO_SUM = 'X' in the field list.
    17. No_subchoice(1) TYPE c : Does not allow the user to interactively change the field chosen for subtotals.
    Value set: SPACE, 'X'
    'X' = value whose change triggers subtotals, provided by the calling program. The user should not be able to change this value interactively.
    18. No_subtotals(1) TYPE c : No subtotals possible          
    Value set: SPACE, 'X'
    'X' = no subtotals.
    19. Numc_sum(1)  TYPE c : Totals only possible for NUMC-Fields.
    20. No_unit_splitting TYPE c: No separate total lines by inh.units   
    21.totals_before_items TYPE c: Display totals before the items   
    22. Totals_only(1) TYPE c :  Show only totals      
    Value set: SPACE, 'X'
    'X' = only total records are output.
    23. Totals_text(60) TYPE c : Text for 1st col. in totals   
    Value set: SPACE, string (max.60)
    ' ' = The first column in the total record contains an appropriate number of '*'s to indicate the total by default. If the first column is wide enough, the string 'Total' is output after the asterisks.
    'String’ = The string passed is output after the total indicated by '*', if the column is wide enough.
    24. Subtotals_text(60) TYPE c : Texts for subtotals
    Value set: SPACE, string (max.60)
    ' ' = In the first column of subtotal records, the subtotal is indicated by an appropriate number of '*' by default. If the first column is not a subtotal criterion, the string 'Total' is output after the asterisks, if the column is wide enough.
    'String’ = the string passed is output after the subtotal indicated by '*', if the column is wide enough and the first column is not a subtotal criterion. If it is a subtotal criterion, its value is repeated after the total, if the column is wide enough.
    ELSE TELL ME I WILL PASTE COMPLETE HELP
    regards

  • How to calculate total number of pages in a script

    hi
    how to calculate total number of pages in a script

    Jyothsna,
    Date:-&sy-datum&
    Time:-&sy-timlo&
    Total No.of Pages:-&sapscript-formpages&
    Page No:-&PAGE&/&SAPSCRIPT-FORMPAGES&
    Give the above said lines in your text editor,and given the paragraph format.Better create one more window and give the above said lines in the text editor.
    K.Kiran.

  • How to calculate total no of days in List column

    Hi,
    I've start date and end date. Can you please help me how to calculate total number of days.
    Column Name = Leave Start Date (05/02/2015)
    Column Name = Leave End Date (19/02/2015)
    Column Name = Total Days (This is calculated column)
    I used below formula but its showing only 14 days however it should show 15 days
    =DATEDIF([Start Date], [End Date],"d")
    Thanks,

    I got the answer
    Formula is
    =DATEDIF([Start Date], [End Date]+1,"d")
    Thanks.:)

  • How to Calculate Avg Stock

    Hi Experts,
    User wants to see Avg stock in the report
    say stock values are as following
    MONTH-StockReceipts- Sales- Closingstock 
    1-          365-     12-     353
    2 -          0-     89-     264
    3-          0-     80-     184
    4-          0-     110-     74
    5-          0-     12-     62
    6-          365-     24-     403
    7-          0-     110-     293
    8-          0-     12-     281
    9-          0-     67-     214
    10-          0-     90-     124
    11-          0-     100-     24
    12-          0-     24-     0
    if user enters 01.01.2011 to 31.12.2011
    Avg stock  should be 189.6(this is the avg of closing stock)
    in this example total Stock Receipts 730, Sales 730 and Clsoing stock on 31.12.2011 is 0.
    in the Report along with this Avg stock there are other key figures also.
    how can we calculate the avg stock value based on every month closing stock between the time interval.
    say if user enter 01.01.2011 to 31.12.2011 then i ahve to consider the 12 periods closing stock
    Regards,
    Chandra

    Dear Chandra,
    Are those months 1 2 3... all selections? i.e there is no calmonth out of the structure isn' it? Then yes my reply doesn't work.
    Because the formula is wrong.Not the key figure .I think you don't have to create lots of key figures.This unique key figure of closing stock is restricted by the user's input and takes the value of everything between that input.E.g if the user inputs 05.02.2011-17.08.2011 then the key figure must take the sum of the values of closing stock between that date, in my opinion.
    Now let me correct the formula, you must divide this key figure to the number of months(forget about the average, it was wrong). And number of months between the user input interval must be calculated by the ABAP code i.e a user exit variable.
    Hope it helps,
    Sunny

  • How to calculate the OPEN QUANTITY in delivery Duelist Report

    Hi Everybody,
       I have a query for finding out the OPEN QUANTITY for schedulines for a delivery.
    If for example the report is run for 2nd of February, it is necessary to
    determine whether there are delivery relevant schedule lines before the
    2nd.
    If yes, we need to know whether there is an open quantity to this line
    item.
    If yes, this open quantity is a negative deviation (we delivered not
    enough).
    If there is no open quantity it is necessary to determine whether for the
    earliest future to be deleviered schedule line, the open quantity equals
    the ordered quantity (VBEP-WMENG),
    if No the the difference between both values equals the positive deviation
    (we delivered more than requested)
    If the open quantity equals the ordered quantity there is no deviation.
    The problem is to calculate the open quantity and the SAP standard there is function
    builder used in SAP standard include MV45AF0O_OFFENE_WERTE_ERMITTEL, the
    function builder is called RV_SCHEDULE_CHECK_DELIVERIES'. But how could we use in this formulae in a Custom delivery report.
    Looking for your helpful suggestions.
    Many thanks in Advance,
    Mira Saikrishna

    Krishna....have a look in the below threads where there was a similar requirement..
    error while using BAPI_OUTB_DELIVERY_CHANGE
    change outbound delivery

  • How to calculate open PO quantity

    Hi all,
    Can you let me know the way to calculate open PO quantity? WHich table do I need to get the value from? THanks in advance.

    Hi
    You can select the Open PO's from MKPF and MSEG tables.
    All the GOODS RECEIPTS will be stored in MSEG table.
    Against each PO item there will be GR's in MSEG table.
    Take related Movement types and fetch the GR's received against each PO item by passing EBELn and EBELP fields to MSEG.
    Again OPEN PO means, If the PO qty is 20 and the GR qty is 15 , then again it's a Open PO. So you have to take the PO qty for each item and take the all GR's for a single PO item (you have to LOOP MSEG, as it contains multiple records for a single EBELN and EBELP) and sum up the GR qty's .
    Again here you have to substract the Returns and GI's depending on the movement types.
    So find the total effective GR qty and compare with PO qty if both are same that PO is closed. If PO qty is more than GR qty it is still OPEN.
    For each Item Check if the PO Item Quantity (EKPO-MENGE) is equal to the NEt total of EKBE-MENGE for VGABE= 1 (For Goods Recept).
    for example EKPO-MENGE = 100.
    and It is Partally GRed for 50 quantity, then it is still open. In this case the BELNR will still be there but it is still open.
    Regards
    Raj

  • Error: Displaying Total stock quantity captured in Delta

    Hi,
    I am facing a problem, in displaying "Total stock qty" in Bex query. If I display qty Date wise, it should show me "Last value" for the current day (if there is no transaction for a Plant material combination).
    I try to elaborate more  my issue -
    (1) Did stock Initialization in R3 ( on 29 Jan 08), with zero stock transfered ticked.
    (2) Filled setup table for 03.
    (3) Loaded BX with "Marker update".
    (4) Did INIT without "Marker update".
    (5) Did Delta with "Marker update". Latest delta is on 30 th Jan.
    (6) Executed bex query.
    There are few Plant Material combinations, for which I get "Total stock qty" value only till 29 Jan 08.
    I am using this Bex query as Snap-shot purpose. It should show me value till the current date.
    If there is no transaction for any Plant Material combo, it should show me the Last value.
    Please help.

    Is the delivery document being flagged for deletion or is it physically being deleted?
    If the document is being flagged for deletion, then your stating about how the process should work for extraction of the document into BW is correct. However, if the document is being phyically deleted from the database, R3/ECC doesn't have any way to identify that this has occurred and therefore won't provide the record with the deletion flag.
    For phyically deleted documents, there are only a few options available for capturing this:
    1) Re-load everything from a Full Repair extraction.
    2) Create a process that can validate if the document on BW exists still in the R3/ECC environment.

  • MCBZ report how to get total stock qty calculation?

    Dear Guru,
            if i checking one material in Tcode:MMBE having unrestricted stock is 356 & reserved qty is 56. After this when i am executing report MCBZ-- Current stock reqmt list & get Total stock qty is 120 for same material.
    can any one tell me how it is calculated (i.e. Total Stock).
    My requirement is we want to see a report which shows diffrence bewtwwen satfey stock & total stock. so i am using this report, if any othere suggestion then please reply me.
    Best Regards,
    Dev

    Dear,
           You can see in MD04 t-code here u can find safety stock and inventory stock.
    Regards
    Ravi

  • How to calculate total for field for particular day. in smart forms

    hi,
             pls help in this problem,
    how to calculate cumulative totals for the particular field in samrtforms

    Hi ,
    Either you can calculate the sum in driver program with
    Loop at where Condition .
    Sum the required field .
    endloop .
    Then pass it to smartforms
    Or
    Double Click on table node .
    In the conditions tab give the required condition .
    select calculation tab.
    In operation select Total , in field name give the name of the field you want to sum
    and in targer field name specify the name of the field that should contain the result .
    To convert the total in to words use the function module in program lines
    CALL FUNCTION 'HR_IN_CHG_INR_WRDS'
    EXPORTING
    amt_in_num = w_total
    IMPORTING
    AMT_IN_WORDS = w_total_words
    EXCEPTIONS
    DATA_TYPE_MISMATCH = 1
    OTHERS = 2
    Regards

  • How to find total stock in a plant

    Hi.
    iam an abap developer i need to print a report which shows material and  total stock in plant.tell me filed name which display total stock
    Thank you,
    madhu

    Hi
    The plant stocks are stored in these tables
    MARD Storage Location Data for Material
    MCHB Batch Stocks
    MKOL Special Stocks from Vendor
    MSKA Sales Order Stock
    MSKU Special Stocks with Customer
    MSLB Special Stocks with Vendor
    MSPR Project Stock
    you can get the Stokc filed from the tables.
    Thanks & Regards
    Kishore

  • How to calculate Opening Stock for a particular date.

    Hi Experts,
    I have a sitution to calculate Opening stock for a particular date.
    please help me with the necessary Fields & Tables required.
    Appriciate If any Sample coding available.
    Thanks & regards,
    Venkat.

    Hi Venkat,
    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.
    Thanks & Regards,
    Dileep .C

  • How to print total stock in smartform by material wise

    Dear Experts,
    I am trying to print total material stock which is issued and receipt during entered date in a smartform ,Here  I want to print totatl stock issued n receipt by material wise in seperate line .For that I fetch alldata and put into one internal table .In smartform I am using table for printing data.
    Edited by: BharatRathod on Mar 8, 2010 11:43 AM
    Edited by: BharatRathod on Mar 8, 2010 11:46 AM

    Hi,
    Try using the CALCULATIONS tab in the tables for printing the total stock in smartforms.
    Regards,
    Sharin.

  • How to calculate Total Shipping Volume in Sales Order ?

    Hello,
    Please give me suggestion for calculating Total Shipping Volume or Total Shipping Quantity in Sales Order.
    And suggest if there is any existing report available to get “Total Shipping Volume”.
    Thank You.
    Regards,
    Meghana

    Hi,
    Thanks for your reply.
    I am not asking of account assignment group for material.
    My problem is when i am creating Sales Order at item level in Account assignment category there is one field for Fund Mangement account assignment grp.
    I want to activate this field and i have to enter FM area in that field.
    Plz send some solution for the same.
    Thanks & regards,
    Pankaj

  • How to calculate total time of mouse movement

    Hi Everyone.
    I am doing project on gesture recognition with touchpad. I need to find out the total time of completion of gesture on touchpad. For that I need to calculate total time of cursor movement on laptop touchpad. When cursor starts moving, that time I need to capture time and when it stops also. I need to find out difference between the start time and stop time. Please help me to do this task. Presently I am trying with event structure and timed structure but I am getting only present time only. I tried with counter but unable to get the difference.

    I missed the mouse move event when I saw this earlier, and for some reason I thought the first attempt would give you what you wanted. 
    Here is a different VI. It uses mouse move event with some logic that remembers the first mouse move event. Otherwise, you won't get the correct time.
    Attachments:
    Mouse Move Time.vi ‏11 KB

Maybe you are looking for

  • Settling Freight Costs

    Gurus u2013 see below regarding SAP shipment cost document (SCD) and the associated Service PO.  Any thoughts on how to correct this? CASE: u2022     Create SCD with reference to shipment number. This SCD creates a Service purchase order and a Servic

  • Display problem - Too Contrasty

    I am using Mac Mini, connected to a HP widescreen LCD monitor via VGA-VGA cable using the adaptor came with the Mini. It was all fine before. But now the display gone too contrasty. I have changed the cable and even the monitor itself (as I thought t

  • Invoking custom object method

    Hi to everybody. I'm looking for a solution to my problem and I hope someone could help me. My classes are the following: public class sharedFunc { public int getMyValue() return 10; public class midClass { public sharedFunc A; public class Main { pr

  • Regarding Lead number by using BAPI_LEAD_CREATEMULTI.??

    Hi Guru's, I am creating lead the Lead using the BAPI_LEAD_CREATEMULTI.and BAPI_TRANSACTION_COMMIT. I want to know <b>Lead Number</b> created by using these BAPI's??Which <b>field</b> will give me the<b> lead number</b>?? thanks in advance, Arjun

  • Help with EXCEPTION_ACCESS_VIOLATION (0xc0000005)

    This is my first time trying to use an external .dll and java wrapper class. Whilst I feel there's nothing wrong with the code (no one else seems to have complained), I get this error message and I'm not quite sure its java's fault. It seems to point