Last Month value for the keyfigure in Report

HI ALL,
how do we get keyfigure value for the last month in the report.
for ex:  for  amount keyfigure should come for the last month  rest of the key figures should come for the current month values.
SBU |    AMOUNT (LAST MONTH VALUE) |      QTY(CURRENT MONTH) |     NETPROFIT(CURRENT MONTH)
The above shown is ex as i required in same manner. Even i restricted with calmonth offset value -1 in keyfigure but it is not working. please help me to get solution .
Thanks
Pinky Reddy

Hi Pinky,
It is not advisable to use offset to get the previous month value.This is not effective in the case when your current month is Jan & u have to get the previous year's dec month value.It is always better to opt for Exits
Do use the code mentioned below.
Note:- ZCUSMFIS3 - Variable in the selection screen for entering current month
           'ZPREVPER - Variable with which the amount key figure has to be resticted.
  WHEN 'ZPREVPER'.
    IF I_STEP = 2. "after the popup
      LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE
                              WHERE VNAM = 'ZCUSMFIS3'.              
        V_PERIOD = LOC_VAR_RANGE-LOW+4(3).
        V_FYEAR = LOC_VAR_RANGE-LOW+0(4).
        V_FVARIANT = 'B1'.
        V_FISCPERYEAR = LOC_VAR_RANGE-LOW.
        IF V_PERIOD = '001'.
          V_PERIOD = '012'.
          V_FYEAR = V_FYEAR - 1.
          CONCATENATE V_FYEAR V_PERIOD INTO V_FISCPERYEAR.
        ELSE.
          V_FISCPERYEAR = V_FISCPERYEAR - 1.
          LOC_VAR_RANGE-LOW = V_FISCPERYEAR.
        ENDIF.
        CLEAR L_S_RANGE.
        L_S_RANGE-LOW = LOC_VAR_RANGE-LOW. "YYYYMMDD - DD will indicate the no of days
        L_S_RANGE-SIGN = 'I'.
        L_S_RANGE-OPT = 'EQ'.
        APPEND L_S_RANGE TO E_T_RANGE.
        EXIT.
      ENDLOOP.
    ENDIF.
Hope this provides the solution for your requirement.
Regards,
Saswati.

Similar Messages

  • To create monthly buckets for a keyfigure in report...

    Hi Gurus,
    I have a keyfigure called Demand in my report.  For Demand, I need to create monthly buckets in the form of columns, ie Demand-Month1, Demand-Month2, Demand-Month3 whereas from R3 the demand values for Month1, Month2, and Month3 flows in rows.  In short, I need to transpose it to columns from the report level in BW. 
    Also, in the description of the columns, for example: If month1 flowing from R3 is July, then Demand-Month1 should be Demand-July, Demand-Month2 should be Demand-August, Demand-Month3 should be Demand-September.
    Can I do this with the help of variables or some other method.  Please help me in detail.
    Thanks,
    Edited by: sachitp on Oct 5, 2010 6:55 PM

    Hi ,
    inorder to design a bucketing report For this you need to create a formula variable with replacement path on the date and take the system date varaible which is provided by SAP.
    create a formula to calculate the difference of days.
    based on the diff of days you can create the formula to get the buckets.
    Check the below blog link which will give you some idea to go ahead.
    Calculating the Ageing of the Materials
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/30f15839-0cf1-2b10-c6a7-ebe68cc87cdc
    REgards
    KP

  • How to Bring the Quarter Period and Previous Month Value for given Input

    Hi to all,
          I want bring Quarter Period and Previous Month value for the given Input. Plz help me on this
    Example :
    Input : 06.2008
    Output:
    Input     Prev.Month  Quarter 1   Quarter 2   Quarter 3 
    06.2008  05.2008      03.2008     12.2007     09.2008
    12.2008  11.2008      09.2008      06.2008    03.2008
      Is there any Standad Exit for this or we have to write coding ?
    Regards,
    Saran

    Hi,
    You can solve this by using Replacement path.There you have a option offsets.Here give the current period.Based on that give the number which previouse month you suppose to want.
    I think this 'll help you
    assign points if this helps
    Regards
    JT Goud

  • Creation of a Query to show the values for the current month and the last 12 months data.

    Dear All,
    Good day!
    I have to create a Query with the below requirement.
    I have to create a Query to show the values for the current month and the last 12 months data.
    Can you please guide me how to achieve this ??
    thank you,
    Regards,
    Hema

    Hema
    explain the exact problem..? as you mentioned you want to create query to show values for current month and last 12 months.. so I think you want to show values for 12 months from current data.. you can achive this by multiple way..
    you can have selection screen and field with date .. and restrict based on system current date and 12 months before or you can handle this at your target.. .. I mean there are multiple ways to restrict data by date range..
    for some more hints..
    http://www.forumtopics.com/busobj/viewtopic.php?t=34393&sid=7fba465d0463bf7ff5ec46c128754ed6
    http://businessintelligence.ittoolbox.com/groups/technical-functional/cognos8-l/how-to-display-last-12-months-in-report-based-on-todays-date-3231850
    http://scn.sap.com/thread/3217381
    search on SDN you will get many other ways..
    Thanks,
    Bhupesh

  • I want better solution for adjusting the Material stock values for the last

    my Customer  need to adjust( Decrease)  the closing stock values for the following materials / plant wise as on 31.03.2006 for meeting statuary compliance.
    Material1 :  RS: 4149599    QTY : 10181.03 Ltrs
    Material 2  : RS: 1318596     QTY:  2152.76   Ltrs
    As per my knowledge MM posting periods can open current month and Previous month only. For the reason I proposed the solution as follows:
    Step 1 : post FI Journal Entry on 31.03.2006
    Opening Balance G/L  Account Dr 4149599 + 1318596
    Closting Stock a/c                      Cr 4149599 + 1318596
    Step 2.
    Change the Material Price in MM through T.Code: MR21
    ( Posting will be allowed in current or previous months)
    This makes our CO reports accurate.
    Please  suggest the better solution if it is possible in MM for adjusting the Material stock values for the last financial year.
    WIth Best Regards,
    Rajesh
    <b></b>

    Hi Madhavan,
    Unfortunately this forum deals with migrations from non-Oracle
    environments to Oracle. You seem to be dealing with migrations in
    an Oracle environment mainly.
    I would recommend that you contact Oracle Applications and RDBMS
    support directly. They will have the most up to date
    information/advice on performing these actions.
    Regards
    John
    Madhavan (guest) wrote:
    : Hi John
    : Thanks for your reply.
    : Actually I am planning to upgrade the system.
    : 1. I Want to Upgrade Oracle Financials release 10.7 to the
    : latest version (11.x)
    : 2. Oracle 7 database to oracle 8 or 8i.
    : 3. Oracle is running on NT service pack 3. Do I need to upgrade
    : this?. If not what is the impact on Windows NT?
    : 4. Is the majority still running smart client 10.7 and database
    : 7?
    : 5. What is the necessary time to implement these upgrades? What
    : type of consulting I need to have?
    : 6. I have some employees working on it? Will these changes
    : affect them?
    : What type of precautions I need to take on the whole??
    : Thank You
    : Madhavan
    Oracle Technology Network
    http://technet.oracle.com
    null

  • How should get last month value from report?

    Hi experts,
    How should last month value. For example
    jan    feb    march
    100   --       ---
    Here i want to get jan month value in march coloumn.

    Hi ,
    It is only show last month value. but my requirement is if last month is empty it should bring Before Last month.
    For Example
      Jan       Feb       Mar
    1000   
    i need if the Feb value is empty should come jan month value.

  • How to get the current month value for a customer exit variable?

    How to get the current month value for a customer exit variable? 
    And also if we have an InfoObject with date value (including date, month, year), then how to derive the month value from this date type of Char.?
    Thanks!

    Hi Kevin,
    Check here........
    Re: Customer Exist for "From Current Date To Month End"
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/25d98cf6-0d01-0010-0e9b-edcd4597335a
    Cal month
    Regards,
    Vijay.

  • My iPhone is about 6 months old now and I would say I don't use it that much. Yet for the last month or so the battery life has been going down and today after having charged it to 100% this morning, it was at 5% at 4 pm this aft. help!!

    my iPhone is about 6 months old now and I would say I don't use it that much. Yet for the last month or so the battery life has been going down and today after having charged it to 100% this morning, it was at 5% at 4 pm this aft. help!!

    Ok Fellas, let me give you a clue:  Games, particularly those that make heavy use of graphics and sound are notoriously power hungry.  In fact, when I was in the Navy many years ago, the folks working on the NTDS (Navy Tactical Data System)  computers used a version of Space Invaders to load test the AN/UYK-43 computers.
    I have also noticed that all of my laptops (I have a brand new Toshiba dual core, an older Toshiba single core, plus 2 Dell dual core machines) have significantly shorter battery life when I play Company of Heroes than when I am just reading e-mail or surfing the 'Net.  I have also noticed the same behavior when I play games on my 4th gen Touch and my iPhone 4.
    The fact is, iOS 5 did make some major improvements as well as adding some nice functionality like iMessage, wireless synch, and such, but the down side is that depending on how you use the device battery life can be shorter that what you may have experienced with pervious versions of iOS.  Its just the nature of the beast...
    We now return you to our regularly scheduled programming.....
    Oh John....  Oh Marsha.....

  • Hi, last month i bought the ms bundle knowing it would help me with my office works..but didnt seem to work as i thought please help me with this, i didnt pay 51 singapore dollar for nothing please get me back asap

    Hi, last month i bought the ms bundle knowing it would help me with my office works..but didnt seem to work as i thought please help me with this, i didnt pay 51 singapore dollar for nothing please get me back asap

    Does the iPod connect to other networks?
    If you restored to factory settings/new iPod and still does not connect to any network that indicates a hardware problem.
    If you only can't connect to your network that indicates a problem with your network.
    Make an appointment at the Genius Bar of an Apple store..
    Apple Retail Store - Genius Bar

  • How to hide dynamic parameters values in the URL with Reports 6i

    Hi,
    I want to know a way of hiding the parameters values when asking for a report through the web.
    Now I'm using the Reports 3.0.5.8 with a Cartridge defined in the Oracle Web Application Server 3.0.1.0.1. When you ask for a report with the parameters DESTYPE = cache and DESFORMAT = pdf, it is fully generated and in the Address or Location box of the browser, you can see http://webserver/cache/report.pdf (where cache is the virtual directory defined in the OWAS in which the .pdfs are cached). So, users cant see the Url used to generate the report.
    Im trying to upgrade this configuration to Reports 6i with Cgi in a web server. I generate reports with no problems. The problem I have is I cant find how to hide the parameters values as before. I mean, when I ask for a report, once its generated I can see http://webserver/cgi-bin/rwcgi60.exe?server=ServerName&report=report.rdf&userid=user/pass@connection&destype=cache&desformat=pdf&P1=value1&P2=value2 in the Location box. It allows user to ask for another report changing the values of the parameters. I use these parameters to execute some query written in the Data Model. For example, imagine that the P1 represents the company id, the user (that is supposed to see only data of its company) can change this id, ask for a new report and see data of another company.
    Ive already tried to use the key mapping option, but its not useful to me because the parameters values are dynamic and its impossible to define different entries in the cgicmd.dat for each possible value. The option of loading the parameter form before running a report is not useful to me either, because there exists specific screens for this purpose.
    Is there any solution?
    Thank you.
    Marma Bonfiglio.

    Hi Rakesh,
      I am using BI  7.0
    The last option I have is 'Hide' for 'Calculate single values as' .
    I have the below options  for 'Calculate single values as'
    1. Normalise  according to Next group  level  Resul.
    2. Normalize according to  Overall Result
    3. Rank number
    4.Olympic Rank Number
    5.Maximum
    6. Minimum
    7.Counter for all detailed values
    8.Counter for all detailed values that are non zero
    9.Moving average
    10.Moving average  That is  Not zero ,null or Error
    11. Hide.
    So could you please tell me where i can find 'suppress result' option for the keyfigure .
    Many thanks

  • Want last month value of a Quarter instead of to-date value

    Hi All
    I have a report that has 2 columns : Quarter-year , Measure1. Quarter-Year can be drilled down to the month level. Now, what is happening is because I only have the Quarter-Year as the dimension column, I'm getting the cumulative (todate) value for the measure. Say I have Q1-2010 drills down to Jan - 10,000 .. Feb-20,000.. Mar-30,000... I want the report
    to show the value as of March (the last month of the quarter): Q1-2010     30,000.
    Instead I see the value as (10k+20k+30k = 60,000). Is there a way of achieving 30,000 value for Q1-2010 in Answers?
    Thanks
    Ananth
    Edited by: Ananth V on Feb 4, 2010 8:54 AM

    Excuse the re-edit, the instructions below will give you a level based measures. if you used function QUARTER_OF_YEAR(expr) you should be able to use a case statement below to only pull Quarters 3, 6, 9 and 12 (ie last quarters) in your measure definition, then use the level based mechanism if required.
    Create another measure (duplicate your existing) and set the level of this measure to 'Quarter' by editing content tab on that measure or dragging it up to the Quarter level in your date hierarchy.
    This will return the Quarter total , regardless of group by- you may need to set other levels in accordance with other dimensions used on the report.
    Hope this helps,
    Rgrds
    Alastair
    Edited by: Alastair_PeakIndicators on Apr 26, 2010 4:12 PM
    Edited by: Alastair_PeakIndicators on Apr 26, 2010 4:13 PM

  • Urgent: Formular question: get first/last month value with qty value

    We've got a query result as the following:
    Jan_2007 -- Feb_2007 -- Mar_2007 -- Apr_2007
    0 --- 54 --- 0 --- 3
    23 ---0 --- 12 --- 7
    In the above query result,
    1st row shows the sales quantity in Jan_2007 is 0, in Feb_2007 is 54, in Mar_2007 is 0, and in Apr_2007 is 3.
    2nd row shows the sales quantity in Jan_2007 is 23, in Feb_2007 is 0, in Mar_2007 is 12, and in Apr_2007 is 7.
    We would like to add a new column to get the first/last month value with quantity, e.g., in 1st row, the 1st month value with quantity value (>0) is Feb_2007, and the last month value with quantity value (>0) is Apr_2007. Therefore the 1st month value with qty is Feb_2007 and the last month value with qty is Apr_2007. In 2nd row, the first month value with qty is Jan_2007 and the last month value with qty is Apr_2007. But how to use formular to get the 1st/last month values with qty?
    We will give you reward points!

    Hello Kevin,  
    You can create forumula using [Boolean Operator|http://help.sap.com/saphelp_nw04/helpdata/en/23/17f13a2f160f28e10000000a114084/content.htm]
    IF<Logic Expression> THEN <Expression1> ELSE <Expression2> can also be made using a formula in the form
    You can also use the [AND, OR Logical operators |http://help.sap.com/saphelp_nw04/helpdata/en/23/17f13a2f160f28e10000000a114084/content.htm]to check all the keyfigure columns.
    Thanks
    Chandran

  • # values for navigational attributes in report . (Urgent)

    Hi Gurus,
    I have a navigational attributes for time dependent master data. In the report I am not able to see values for that navigational attribute. I see # values for the navigational attributes. I checked the master data of main info-object. every thing looks fine.
    please help me in regarding this.
    thanks,
    Regards,
    Aarthi

    Check the following two things again just to make sure you are doing everything right. These are already mentioned by Bhanu...
    1) Go to the master data table (Q  table or the M table) and check to see if there are M version records (OBJVERS = M). If yes, you need to activate the master data using the program RSDDS_AGGREGATES_MAINTAIN (Change Run). If there are no M version records then check the second step
    2) If you do not enter any key date in the query, it takes the system date as the default key date. So check and see if any master data exists for today's date ?
    Also just curious, which version and support pack level are you on ?

  • Need to place a variable value at the end of report heading in BI 7

    Dear All,
    We have to place a variable value at the end of the report heading and the value should get refreshed whenever we change the variable by using "Change Variable Value". I have created a macro and the value will get triggered unless and until we click on any where on a sheet. But, we want to automate this one by using a macro.
    Ex: Quarterly TA Host Country Details As Of "Variable Date" Variable is created on TA Date characteristic. User can enter date on Pop up window box at the time of changing a variable TA Date. We need changed date at the end of the Report heading Qua----
    Please suggest me on how to place variable value at the end of report heading by using a macro.

    No need to use Macro. You can use text variable.
    Goto the Query Description and click on the Text variable icon.
    Create a text variable of processing type as REPLACEMENT PATH and replace it with the characteristic for which you have a ready for input variable that will be eneter by the user.
    This will populate the text variable with the value entered by teh user.
    Use this text variabkle along with the Query Description. So your description will look something like REPORT_TITLE&TXT_VAR&
    Hope this helps.

  • How do I get a new value for the service name field and update it in Connection Properties?

    I am running Windows Vista. I just upgraded to Firefox 4. When I try to log on to the internet, it tells me the proxy server is refusing connections. A diagnostic reported Error 815 and said the remote server is not responding because there is an invalid value for the "Service Name" field. It said to get a new value and update it in Connection Properties. How do I do this?

    When you create a new film script, the first page you see is a title page.
    The page after this title page is the one where you generally type in your scenes.
    It looks like you are facing some issue and not able to delete any text.
    Can you please send me this script so that I can have a better look at your issue?
    You can save this script to disk by using option 'File -> Save to disk'. This will create a '.stdoc' file on your system.
    Just mail this '.stdoc' file to me at 'roverma <at> adobe <dot> com'
    Thanks

Maybe you are looking for

  • My movies and music videos won't show up on screen, I can hear the sound but not see the video how do I fix this?

    My movies and music videos won't show up on my computer screen, I can hear the sound but not see the video how do I fix this? I'm not sure what to do as far as turning my purchased movie into DVD goes either. I just want to put the movie onto a DVD d

  • Using 'OR' in web services 1.0 query.

    HI, I need to query for a particular contact on the basis of Phone number. Now the search for the Phone Number search should be on 3 fields WorkPhoneNumber, CellPhoneNumber, HomePhoneNumber. contact.setWorkPhoneNumber("='" phoneNumber"'"); contact.se

  • SELECT command using String

    Hi How can I do to select data using string with range: srch_strA = notcr-low. srch_strb = notcr-high. * Building selection IF srch_strA IS NOT INITIAL AND srch_strB IS INITIAL.   CONCATENATE '%' srch_strA '%' INTO srch_strA. *document header   SELEC

  • Basic list query.....

    I am developing report in which output will be in Basic list (Using only write statement). my requirement is to provide some type of navigation or any other way to maintain values in Z TABLE which is master table for this table. Please help  me .

  • How to prevent a file from stripping?

    I'm building vacation for Arch64 but should be the same for 32bit. PKGBUILD looks like this: # $Id: PKGBUILD,v 1.1 2004/01/21 15:43:15 dale Exp $ # Maintainer: dale <[email protected]> pkgname=vacation pkgver=1.2.6.1 pkgrel=1 pkgdesc="an automatic m