Records for parameter month and previous month

Hi,
I have a request where the user parameter is calender year month (YYYYMM).I need to show the records of both the entered month and previous month.
For ex: if the user enters 201107, I need to show the records of 201107 and 201106.
Also,I am not using dashboards.
Any suggestion...
Thanks

No, I don't see this as a solution. A session prompt can only be overridden by using a Request Variable, but they are found in Dashboard prompts which you have excluded as a solution. Therefore, any session variable you set would be "hard-coded" eliminating end-user interaction. Sorry.
You will need to deploy dashboards for this. I will also add this: eliminating dashboards really restricts the power of OBI because it makes it difficult to implement interactive reports such as the one you are building. Perhaps you should use this example as a push to consider adding the value of dashboards to your environment.
As this is useful information to others, please mark applicable posts that resolved your question. Thanks.

Similar Messages

  • Parameter for Current Month and Previous Month

    I'm trying to create a parameter for current month and previous month based on the ex_date, but not sure what i'm doing wrong. 
    where ex_date = @SelectDate
    I created a second dataset below for the values in the parameters.
    SELECT Month(CURRENT_TIMESTAMP) AS 'Month', 'Current Month' as 'Current Month'
    union all
    SELECT Month(CURRENT_TIMESTAMP)-1 AS Month, 'Previous Month' as 'Previous Month'
    Results
    Month Current Month
    3 Current Month
    2 Previous Month
    Once I preview it I get "Conversion failed when converting date and/ or time from character string" I changed the data type to "date/Time" but that did not make a difference. The date is convert (varchar(10), ex_date, 101) so looks like
    11/12/2014. 
    I've also tried expressions like =month(now()) to pull current month with same error so i'm not sure what i'm doing wrong. Any ideas?

    i tired this real simple report
     in the first dataset - my main report query - select name from sysdatabases where month(crdate())=@month
    in the second dataset - select month(getdate()) as Month1
    in the parameters - choose int data type and available values - select the second data set
    in the first data set- add this parameter..( i am assumming you know this, since you have done)
    in the preview you should get the drop down with current month number - 3
    and if you run the report, it will display the database names that were created in march. remember we are no checking year, so will get all that were created in march across the years.
    Hope it Helps!!
    I'm looking to have the dropdown say "Previous Month" and "Current Month" as a option. I know how to get the information in SQL, but not sure how this translates or put into a parameter.
    Current Month
    list_date BETWEEN
    DATEADD(MONTH, DATEDIFF(MONTH, 0, GETDATE()), 0)
    AND
    DATEADD(MONTH, DATEDIFF(MONTH, 0, GETDATE()) + 1, 0)
    Previous Month
    list_date between
    CONVERT(varchar,dateadd(d,-(day(dateadd(m,-1,getdate()-2))),dateadd(m,-1,getdate()-1)),106) /* Last Month */
    and
    CONVERT(varchar,dateadd(d,-(day(getdate())),getdate()),106)

  • OLAP Universes - Based on BEx Query - Month and Previous Month Functions

    Hi,
      I created a Universe based on SAP BEx queries and I like to create a filter so that I use in Web Intelligence report to run for "Previous Month" data always. There are "Date" filelds in BEx Query(No Month info only date data). I have no knowledge of SAP BEx Queries and new to OLAP universes. Could you help.
    How to create filter that show Previous Month.
    Nanda Kishore
    Edited by: Nanda Kishore B on Dec 26, 2010 6:15 AM

    The easiest way  (but NOT the most efficient one) is to create a local variable (Dimension) in your report with the following code:
    =if (Month(CurrentDate())=1 AND Month([[MyDate]])=12 AND Year([[MyDate]])=(Year(CurrentDate())-1)) OR (Month(CurrentDate())>1 AND   Month([[MyDate]])=(Month(CurrentDate())-1)) then 1 else 0
    where MyDate is the field from your query containing the data information
    Activate the report filter area in your report design panel by pressing the Report filter icon and drag and drop your variable there and apply it to the entire report. Filter value 1 and you will get the data for the previous month.
    Keep in mind that this approach is not optimal especially if you do have many rows of data delivered to your WebI report because filtering takes place only AFTER the data is retrieved. The Best practice here is to work with BEx variables.
    How many rows of data does your WebI report normally fetches?
    Regards,
    Stratos

  • Set variable date in a procedure with current month and previous month

    Hi guys, I need to set two date range in one procedure. The date should be
    @datefrom the third day of the current month
    @dateto the seventh day of the current month
    @datefrom-1 the third day of the previous month
    @dateto-1 the seventh day of the previous month
    format like @datefrom '2014-03-03' @dateto '2014-03-07'
    @datefrom '2014-02-03' @dateto '2014-02-07'
    The problem for me it's going to be the jump between the years...2014 to 2015...any advice?
    Thanks

    DECLARE @FirstDayOfCurrentMonth DATE
    SELECT @FirstDayOfCurrentMonth = DATEADD(MONTH, DATEDIFF(MONTH, '01/01/1900', Current_timeStamp), '01/01/1900')
    SELECT
    DATEADD(DAY, 2, @FirstDayOfCurrentMonth) As ThirdDayOfCurrentMonth
    ,DATEADD(DAY, 6, @FirstDayOfCurrentMonth) As SeventhDayOfCurrentMonth
    ,DATEADD(DAY, 2, DATEADD(MONTH, -1, @FirstDayOfCurrentMonth)) As ThirdDayOfPreviousMonth
    ,DATEADD(DAY, 6, DATEADD(MONTH, -1, @FirstDayOfCurrentMonth)) As SeventhDayOfPreviousMonth
    OUTPUT
    ThirdDayOfCurrentMonth SeventhDayOfCurrentMonth ThirdDayOfPreviousMonth SeventhDayOfPreviousMonth
    2014-12-03 2014-12-07 2014-11-03 2014-11-07
    Best Wishes, Arbi; Please vote if you find this posting was helpful or Mark it as answered.

  • Current month and Previous Month

     Hi, I have the table shown above. I m trying to get output something like I need current month total amount and the total of the previous month. Can someone please help on this?  THank you
    ID           PreviousMonthTotal        CurrentMOnthTotal      
    1              3000                                3000                   

    Please say your @@version,
    on
        Microsoft SQL Server 2012 (SP1) - 11.0.3412.0 (X64)
        Mar  2 2014 01:25:09
        Copyright (c) Microsoft Corporation
        Standard Edition (64-bit) on Windows NT 6.2 <X64> (Build 9200: )
    query show ZEROS.
    DECLARE  @TEMP as TABLE
        id int,date_t datetime,amount int
    INSERT @TEMP (id,date_t,amount)
    VALUES   (1,'20150112',1000)
            ,(1,'20150212',1000)
            ,(1,'20150122',2000)
            ,(1,'20150202',200)
            ,(1,'20160112',41000)
            ,(2,'20150112',1001)
            ,(2,'20150212',1003)
            ,(2,'20150122',2004)
            ,(2,'20150202',205)
            ,(2,'20160112',41020)
            ,(2,'20160212',11200)
            ,(2,'20140122',201)
            ,(2,'20140202',20)
    SELECT ID as [Cust Ref]
    , SUM(CASE WHEN Date_t = dateadd(MM,-1,getdate()) THEN Amount ELSE 0 END) as [Total LAST Month]
    , SUM(CASE WHEN Date_t = getdate()  THEN Amount ELSE 0 END) as [Total This Month]
    FROM @temp
    GROUP BY ID

  • Current month and previous months of fiscal year period data

    Hi All,
    My requirement is end user will enter month ie (fiscal year period ) and in report my requiremnt is to show data in two columns 1.Current month data  and
    2.April till date.
    Please let me know how to do this and please send the coding to be done in CMOS.
    Regards

    Hi,
    In your query, you should have following object :
    in filters:
    fiscal period object, with an user entry variable on it (UE_MONTH)
    in rows/ratios:
    Current month column, with your KF and a restriction on 0calmonth2 with an customer exit variable on it (ie: CE_VAR1)
    same for April column. (CE_VAR2)
    in your customer exit, CMOD, step 2, add these two cases :
    WHEN 'CE_VAR1'.
    READ TABLE i_t_var_range WITH KEY vnam = 'UE_MONTH' INTO
                       intern_range.
    CONCATENATE intern_range-low(6) sy-datum+4(2) INTO l_s_range-low.
    l_s_range-sign   = 'I'.
    l_s_range-opt    = 'EQ'.
    APPEND l_s_range TO e_t_range.
    Same for April, add a new case and just replace sy-datum+4(2) by '04'.
    Hope it helps,

  • Show current month and previous month measures

    Experts,
    My period names are stored like this in the Period Dim table 'Jan 2012'.....'Aug 2012', ... 'Dec 2012' etc..
    To my request, i will pass only the current period value via. a drop down prompt, say 'Feb 2013' and it has to apply filter like this Period."Period name" in ('Feb 2013', 'Jan 2013').
    I cannot use TIMESTAMPADD(SQL_TSI_MONTH, -1, Period."period name") as my period name is a char. Can someone suggest any idea?
    Version : 10.1.3.4
    Regards,
    Sarvan

    Hi,
    This can be achived,but little bit tedious process...
    Create an intermediate report with three columns.
    first column : Monthcolumn,which you are using in prompt.
    Second column :This column is for selected month
    Try to convert Jan 2012 to 201201,Feb 2012 to 201202...This can be achieved by writing a case statement like below
    cast((Case when substring(column from 1 for 3)='Jan' then 01...........)||substring(column from 5 for 4) as int)
    Third column:Prior month
    cast((Case when substring(column from 1 for 3)='Jan' then 01...........)||substring(column from 5 for 4) as int)-1
    Now add the same column formula to the main report and hide it(let's say column name will be "HIDED")
    cast((Case when substring(column from 1 for 3)='Jan' then 01...........)||substring(column from 5 for 4) as int)
    Now you can apply filter based on another request on the hided column.
    HIDED<=Second column in intermediate report.
    HIDED>=Third column in intermediate report.
    Now you will get the desired reults in your report.
    Hope this helps.
    Thanks,
    Pramod.

  • 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

  • Previous month first data and previous month last date

    can any body have query to get previous month first date and previous month last date.
    Ex: First day of the previous week:
    TIMESTAMPADD(SQL_TSI_DAY,-6, (TIMESTAMPADD(SQL_TSI_DAY, DAYOFWEEK(CURRENT_DATE) *-1,CURRENT_DATE)))
    Last day of the previous week:
    TIMESTAMPADD(SQL_TSI_DAY, DAYOFWEEK(CURRENT_DATE) *-1,CURRENT_DATE)
    can anybody have it for first day of the previous month,last day of the previous month?
    Edited by: user12255470 on Apr 7, 2010 3:30 AM

    Hi,
    1st day of previous month :
    TIMESTAMPADD(SQL_TSI_DAY, ( DAYOFMONTH(TIMESTAMPADD(SQL_TSI_MONTH,-1,CURRENT_DATE)) * -1) + 1, TIMESTAMPADD(SQL_TSI_MONTH,-1,CURRENT_DATE))
    last day of previous month :
    TIMESTAMPADD(SQL_TSI_DAY,DAYOFMONTH(TIMESTAMPADD(SQL_TSI_MONTH,-1,CURRENT_DATE)) * -1 , TIMESTAMPADD(SQL_TSI_MONTH, 1, TIMESTAMPADD(SQL_TSI_MONTH,-1,CURRENT_DATE)))
    Please mark Q answered and award points for correct answers !
    Thanks
    Alastair

  • How to display records based on current month and last month???

    i have a query that want to display the data for current month and last month. when i try to view the reports, all the data/key figures is return all in 0.00.
    i modify the variables for this current month and last month but still the results is the same. i could not see the data. any advise on how to modify the variables for this current month and last month? i am thinking my variables is wrong.
    for the current month variable:
    the type of variable is characteristic value, processing by customer exit, reference characteristic is calendar year/month.
    thanks for all who are kind to help me here....

    Hi,
       If you install the variables from BC correctly and they are in active state, you can use them directly use them. check for this month the total values at info cube is ZERO or some value. as you told you are getting ZEROS for your input.and check the data at cube level based on your query design, apply all restrictions, fileters and see do you get any data at cube level and compare with report.

  • Need to create high & low payment based on 20% down for both 36 and 42 month lease terms.

    I have 3 different tables on my worksheet and need to formulate low and high payment scenarios for both 36 and 42 month lease terms based on 20% down. Help.

    trods wrote:
    Anyone?
    Patience, trods. Remember that this is a user-to-user forum, and the participants arrive when they choose to or are able to, not according to a work schedule set by an employer.
    On your question:
    So far you have supplied two factors, and implied a third, that would affect the size of the payments to be made:
    Total amount, downpayment as a percentage of the total amount, and the term on the agreement in months.
    From that you want to calculate a "low payment scenario" and a "high payment scenario" for a term of 36 months, and the same two scenarios for a term of 42 months.
    Missing from the data is whatever factor determines how a "low payment scenario" differs from a "high payment scenario." What's missing?
    Regards,
    Barry

  • My iPhone 4 getting off automatically while battery 60% or more and turn on when i plug in please advice it is battery problem or hardware i use this mobile for 2 years and 3 month.

    My iPhone 4 getting off automatically while battery 60% or more and turn on when i plug in please advice it is battery problem or hardware i use this mobile for 2 years and 3 month.
    Thanking you.

    1.  you may have to take it in to Apple and get an out of warranty iphone for $199.
    2.  you can get your information from a backup of your phone.  you do have a backup of your phone right either in iTunes or icloud.  If you don't then your answer will be no.

  • Formula to subtract current month from previous month

    Hi
    I would like to how to subtract current month from previous month in Crystal 10.  Basically am looking at the variations that between the two month .   I would also like to know the 12 m onth rolling data formula.  Using the same formula, you need to get the difference between the two month.
    Any help on this is very much appreciated.
    Thanks
    Regards
    Cauvery

    Hi Thanks for reponding.
    Though the formula is correct, I don't think it will work out in that way because I have a 12 months rolling data  formula and using this formula  I have to subtract the current month from previous month.
    This the formula that am currently using for 12 months rolling data
    {HPD_HelpDesk.Arrival Time} >= DATEADD ("yyyy", -1, CURRENTDATE)
    Please advise.
    Regards
    Cauvery

  • How to get data for current week and previous week using customer exit in Bex.

    Hi everyone,
    I have a scenario in which I need to display data for current week and previous week (based on "sy_datum" the program has to calculate current week and previous week) in Bex using  Customer exit. I have created one variable in Bex Query Designer and I have written code for the variable in CMOD. But it is not working fine, (I know that we can do the same by using offset value in Bex). Can some one guide me how to achieve my requirement using customer exit.
    Thanks in Advance,
    G S Ramanjaneyulu.

    Hi krishna,
    Thanks for your quick reply, can you have a look at my code,
    case i_vnam.
    WHEN 'ZPWK_CWK'.
    ranges : pre_week for sy-datum.
    data : start_date type DATS,
           end_date TYPE dats .
    ************FM TO GET FIRST DATE OF CURRENT WEEK ************************
    CALL FUNCTION 'BWSO_DATE_GET_FIRST_WEEKDAY'
      EXPORTING
        DATE_IN  = sy-datum
      IMPORTING
        DATE_OUT = start_date.   " WEEK FIRST DATE
    end_date = START_DATE + 6.   " WEEK LAST DATE
    END_DATE   = START_DATE - 1.   " PREVIOUS WEEK END DATE
    START_DATE = START_DATE - 7.   " PREVIOUS WEEK START  DATE
    **********PREVIOUS WEEK DATES IN PRE_WEEK******************
    pre_week-SIGN   = 'I'.
    pre_week-option = 'BT'.
    pre_week-LOW    = START_DATE.
    pre_week-HIGH   = END_DATE.
    APPEND  pre_week.
    CLEAR : START_DATE,END_DATE.
    endcase.
    Regards,
    G S Ramanjaneyulu.

  • Balance sheet required for current quarter and previous quarter

    Hi Guys,
                 I am using 0FIGL_C10 cube for balance sheet report,i need to create balances for current quarter and previous quarter.
    user will enter the fisper, based on fisper it has to show the current quarter and previous quarter balance.
    how to calculate the quarter using fisper.

    you can use offset with ranges.
    or
    just offset of -1 , -2 & -3 seperately in 3 selections and add it in one column in formula (this will give u current quarter).
    similarly offset of -4, -5 , -6 will give u previous quarter result.
    total of 6 selection and 2 formulas. hide all selections from display.

Maybe you are looking for

  • Erratic behaviour map operation after table comparison

    BODI XIR2 11.7.3.6 We want to detect and store changes in source data and store these changes in the target table. After the table comparison the row has got an update operation code flag and goes to a Map operation that converts Update row types to

  • Number of elements that can be used with 'in' Operator

    One of my SQL query having 'in' operator failed saying number of elements exceed. Is there a limit on number of elements that can be used with - 'in' operator. And if yes can it be increased?

  • How to check whether system privilege are granted

    How to check whether system privileges like 'create session' and other ones are granted for user. Is there any sys table where this information is available? Regards - Neuron

  • Migration to JES4 Best Practices

    We are migrating users from our iMS52hf2.12 systems to our new JES4 systems with T118207-52 imstalled. We are looking at putting the account on hold,copying the mailbox updating LDAP attributes (store and partition). What are the commands and sequenc

  • Require SSL for IMAP (and possibly, SMTP)

    Hello, I'm having quite a bit of trouble changing the server configuration to require SSL for IMAP connections on the server side.  (Ideally, I'd like to require SMTP to send email as well, but not require for outbound connections from other hosts as