LAST Aggregation and AGO Function in OBI Administration Tool

I'm struggling a bit with the AGO function and LAST aggregation. The problem is when I try to compare balance from the last day from last month compared with last day of this month.
To get the balance of the last day of this month, I'm using based on dimensions LAST aggregation in the logical column KNSALDOPROMEDIOlast (avg balance).
KNSALDOPROMEDIOlast:
Dimension Formula
Other SUM(BWM.DWH_FTASA.KNSALDOPROMEDIOlast)
DTIEMPO_Dim LAST(BWM.DWH_FTASA.KNSALDOPROMEDIOlast)
To get the last day of last month I’m using the existing logical colum KNSALDOPROMEDIOlast applying the AGO function over the time dimension Month -1.
KNSALDOPROMEDIOlast-1:
AGO(BWM.DWH_FTASA.KNSALDOPROMEDIOlast, BWM.DTIEMPO_Dim.MES_Dim,1).
The problem is when the last month has more days than the current month.
Example:
Month     Last Day     KNSALDOPROMEDIOlast     KNSALDOPROMEDIOlast-1
JAN 2010     JAN 31     437,880,393     0
FEB 2010     FEB 28     484,804,165     442,880,934
MAR 2010     MAR 31     562,201,480     484,804,165
APR 2010     APR 30     583,255,351     570,661,690
MAY 2010     MAY 31     663,660,138     583,255,351
1. The balance of last day of previous month of February is 442,880,93, is wrong this amount, is from Jan 28th, the real is 437,880,393 from last day of January, Jan 31st. January has more days than February.
2. The balance of last day of previous month of March is 484,804,165, is correct this amount is from last day of February, Feb 28th. March has less days than February.
3. The balance of last day of previous month of April is 570,661,690, is wrong this amount, is from mar 30th, the real is 562,201,480 from last day of March, Mar 31st. March has more days than April.
4. The balance of last day of previous month of May is 583,255,351, is correct this amount is from last day of April, Apr 30th. April has less days than May.
Edited by: user10541559 on Aug 18, 2010 1:44 PM

Hi,
I'm not sure about your issue.
The aggregation option "LAST" is used when you need the last value, the most typical example of this is inventory, if you want the inventory quantity of a product in a month, you don't sum the value for each day in the month, you only get the value of the inventory in the last day of required month, right?
Have you tried using session variables?
You can get the last day of the last month from Oracle DB with the function "LAST_DAY". For example:
SELECT LAST_DAY(ADD_MONTHS(CURRENT_DATE, -1)) from DUAL
I know that is not exactly what you need, but I hope I gave you an idea what other things you can try.
Regards,
Jorge.

Similar Messages

  • Todate and AGO function in both Fiscal yer and Calendat year

    I want to create report having column with Todate and ago function formulas. I have to display the facts both in fiscal year and calendar year... how to do this? What value shall i choose in the content tab for the time dimension in this case? My fact table has values for each day...
    I am able to display only columns with fiscal year in time series function with timeDim.fiscal_year... similarly only calendar year with time seriese with calendar year columns... In my hierarchy, I have two branches for Time Dim...one is Fiscal and other is Calendar... and they both are at same level
    Help!

    I have an answer for you...Since you have a correctly defined time dimension (with branches - Fiscal Year->Fiscal Qtr ->Fiscal Month->Fiscal Week and Calendar Year->Cal Qtr->Cal Month->Cal Week->Cal that I assume have the common Child level - Day...) - you should have no problem building time-series logical columns
    In TODATE and AGO you must use relevant Time Dim Level - for example:
    AGO (Column, TimeDim.FiscalYear, 1) = would give you data for previous fiscal year
    AGO (Column, TimeDim.CalYear, 1) = would give you data for previous calendar year
    same goes for qtrs, months, weeks
    If you want to take it to the lowest level Day - it won't matter if you pick Fiscal or Calendar since it's essentially the same.
    I hope this is helpful

  • Problems while trying to open OBI Administration Tool

    Hi everybody,
    I’m getting an error while trying to open the OBI Administration Tool. I performed properly the installation with the client installer, and then created the ODBC connection to the OBI Server, which is hosted in a Red Hat Enterprise Linux 5 (64  bits).
    The error I’m getting is the next one:
    Microsoft Visual C++ Runtime Library
    Runtime Error!
    Program: C:\Program Files\Oracle Business Intelligence Enterprise Edition Plus Client T...
    This application has requested the Runtime to terminate it in an unusual way.
    Please contact the application's support team for more information.
    This is an error that seems to have appeared previously on the forum, but unfortunately I didn’t find any fixing solution. I found posts speaking about cleaning the boot and reinstalling the Visual C++ running components, but they don’t work (at least in my case).
    Any idea?
    Thanks in advance,
    Hibai.

    Hi,
    I have one more question. I need to migrate the database from US7ASCII to UTF8.
    For this I ran csscan for user "TEST" as well as against full database.
    Below log is the csscan output against full database. but my application is depended on TEST schema only. Shall I need to migrate SYS objects data as shown below or it's not required?. If required how to migrate these objects data?
    Looking forward you help.
    USER.TABLE Convertible Exceptional
    SYS.METASTYLESHEET 58 TEST.Table_1 9 0
    TEST.Table_2 11 0
    TEST.Table_3 17 0
    TEST.Table_4 11 0
    [Distribution of Convertible Data per Column]
    USER.TABLE|COLUMN Convertible Exceptional
    SYS.METASTYLESHEET|STYLESHEET 58 0
    Thanks,
    Sankar

  • TODATE and AGO function errors in OBIEE

    I have aggregated time dimension. The time calendar comprises of the following structure with a physical table for each level in the Physical Layer -
    Year -> Half Year -> Quarter -> Month -> Week -> Day
    These tables form the calendar. The RPD works fine until I use the TODATE and AGO based fields in the query.
    When I use the AGO and the TODATE time series function to generate the YTD and PY YTD calculations in the Business Modelling Layer. The system gives the following error on Answers -
    Error Codes: OPR4ONWY:U9IM8TAC:OI2DL65P
    State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 22045] AGO function is used on a time dimension which is logically snowflaked. (HY000)
    SQL Issued: SELECT "- Retail Calendar"."Year Identifier" saw_0, "- Sales"."Gallons Sold" saw_1, "- Sales"."Profit Amount" saw_2, "- Sales"."Sales Quantity" saw_3, "- Sales"."Retail Sales Amount" saw_4, "- Sales"."Licensee Sales Amount" saw_5, "- Sales"."% Retail Sales Amount" saw_6, "- Sales"."% Licensee Sales Amount" saw_7, "- Sales"."Store Average Profit" saw_8, "- Sales"."Sales Amount - Last Year" saw_9 FROM "Reporting Objects" ORDER BY saw_0
    Let me know what I am doing incorrect here?
    I have checked all the joins to see if the time calendar has been incorrectly joined, but I can't find anything. Please help.

    Below are the physical tables involved -
    Year - TIME_YEAR_DM
    Half Year - TIME_HALF_DM
    Quarter - TIME_QTR_DM
    Month - TIME_MTH_DM
    Week - TIME_WK_DM
    Day - TIME_DAY_DM
    Each of these tables has an Identifier key (for example, YR_IDNT, HALF_IDNT, QTR_IDNT, etc.) that uniquely identifies the rows. I am using these IDNT fields as my hierarchical keys.

  • Last argument in AGO function

    Hi Everyone...
    Hope everyone is good .
    So we have this requirement where user want to see selected quarter last month, then previous quarter last month and previous year last month based on Year and Quarter selection. for example.
    Prompts: Year - 2013; Quarter - Q2
    Selected Month (1)
    Last Qtr Last Month (2)
    Diff of 1 - 2
    Last Yr Last Month (3)
    Diff of 1 - 3
    Country
    Jun-13
    Mar-13
    Qtr Diff
    Dec-12
    Yr Diff
    USA
    1000
    500
    500
    700
    300
    UK
    1500
    900
    600
    1200
    300
    Now if user select Quarter as Q3 then report will show:
    Selected Month (1) - Sep-13
    Last Qtr Last Month (2) - Jun-13
    Last Yr Last Month (3)- Dec-12
    So the idea is to take always last month of selected last month, last qtr last month and last yr last month.
    Now I am using AGO function to get the Last Yr Last Month (3) where I need to pass the last argument as a dynamic value.
    AGO("measure","month","month Number")
    But OBIEE say that the last argument should be a consistent integer. So is there any way where we can pass dynamic value of "Number of Period". For example
    for Q1 : AGO("measure","month",3)
    for Q2 : AGO("measure","month",6)
    for Q3 : AGO("measure","month",9)
    for Q4 : AGO("measure","month",12)
    I can use CASE statement for this but will it not create performance issue, just curious?
    Please help me if we can do this in this way or can you please suggest me any other way to do this.
    Thanks,
    Suhel Dayer

    Any thoughts here.... Need help..
    Appreciate your time and efforts.
    Thanks....
    Suhel

  • Level based measure and AGO function

    Hi,
    I've a TIME fact table with a single dimension (TIME_DIM) and a single measure (WORK_DAY).
    WORK_DAY is 1 if the day is a working day, otherwise it is 0.
    This way I can get the number of working days by month, quarter and year.
    (TIME is a logical fact table. WORK_DAY is phsical stored inside the physical TIME_DIM).
    To have WORK_DAY work correctly when used with others fact tables, I've defined it as a level based measure, where all the dimensions are set to the "total" level, apart TIME_DIM.
    So far so good.
    Then I created a new calculated measure WORK_DAY_PREVIOUS_YEAR.
    I used the AGO function this way: AGO (TIME.WORK_DAY, TIME_HIERARCHY.YEAR, 1)
    No complains by OBIEE, but this column always returns 1...
    I've no trouble using level based measures.
    I've no trouble using AGO.
    But if I mix them together they no longer work.
    Do you experience this issue? Any workaround?
    I'm using OBIEE 11.1.1.5
    Regards,
    Corraod

    What is the month level key column functionality in your time dimension?
    it should be in format of yyyymm but not in just mm ..

  • OBI Administration Tool

    Hello gurus.
    Is there in Oracle BI Administration Tool a possibility to connect to another server without a terminal session (remote desktop connection)?
    I want to run from my computer the repository (be able to change it) without terminal session.
    Thanks.

    follow these
    http://www.oraclenerd.com/2010/01/obiee-connect-to-remote-rpd.html
    http://gerardnico.com/wiki/dat/obiee/obiee_client_tools

  • Last played and playcount function

    When will this *bug* be fixed for itunes? i use my itunes to DJ and it helps greatly with letting me know how many times a song has been played and when it was last played. I use the crossfade so turning the crossfade off is not an option for me, as i have read on forums that that is the solution. any help or ideas are greatly appreciated, thanks

    Turning Crossfade Songs off solved the issue for me. I have an additional observation: I just donwloaded two albums from iTunes Store: The Beatles Red and Blue Album. When playing the albums in iTunes (for Mac) in sequential (ie, non-random) order, all play counts properly increased from 0 to 1 EXCEPT for the first and last songs on each album (eg, "Yesterday!" and "Help!" in the Red Album). After truning crossfade off, the play count increased properly.
    When "turning crossfade songs" back on, the play count does not increase for those first/last songs again, so I have to keep crossfade turned off permanently.

  • How to Oracle Database Function in OBIEE Administration Tool

    Hi All,
    I want to use a Oracle Database Function in as a column in OBIEE (BM, Presentation Model). Can anybody has done this inOBIEE. Any pointers to this is much appreicated.
    Thanks,

    Hi user7417334,
    You cannot use any formulas in the presentation layer (not that I know of). But you can definitely use oracle database functions in the BMM layer.
    You want to use the EVALUATE function. It works like this:
    e.x. EVALUATE( 'TO_DATE(%1,%2)' AS DATE, '12/31/2009', 'MM/DD/YYYY')
    Generic Version: EVALUATE( '<FUNC>' AS <DATATYPE>, VALUE1,VALUE2,etc)
    FUNC) Is the syntax for the function you are calling. Any parameters have to be replaced by %<number>, where number refers to the order in which you specify your parameters.
    DATATYPE) The datatype that the function will evaluate to. In this case, DATE.
    VALUE1) The latter part of the formula is a comma separated list of all the parameters used in the function. In this case, it's the date I want to cast
    VALUE2) This is the second parameter. You need as many as you referenced in your function. In this case, it's the date format.
    Good luck and if you found this post useful, please award points!
    best regards,
    -Joe

  • Assigning App Builder and Application roles using Account Administration Tool

    If you have a DPS Enterprise or Professional Account and need to assign App Builder or Application role to an id to in case you need to create a new id with these roles, refer to the following documentation:
    Assigning App Builder and Application roles in your DPS Professional or Enterprise accounts

    gnm,
    Please refer to KnowledgeBase 2IDDCHB9: Using Remote Panels with a LabVIEW Applications (EXE) for the information you are looking for.
    Randy Hoskin
    Applications Engineer
    National Instruments
    http://www.ni.com/ask

  • [HELP] AGO function return wrong result

    Hi, i try to implement ago function in OBIEE, but the result is not as expected. Please help me to configure Time Dimension to get this work.
    My case:
    - I have a time dimension with this configuration:
    [http://i264.photobucket.com/albums/ii176/necrombi/NEO/1-1.png]
    Time Hierarchy: Total > Year > Quarter > Month > Day
    Year:
    Primary key: Calendar_year_cal_year_code
    Chronological key: Does not define
    Quarter:
    Primary key: Calendar_quarter_description
    Chronological key: Does not define
    Month:
    Primary key: Calendar_month_description
    Chronological key: Calendar_month_description
    Day:
    Primary key: Dimension_key
    Chronological key: Day_day_code
    My ago function: AGO(expression, mywh.D_qn_thoigianDim."month", 1)
    I do not understand why i get this wrong results:
    [http://i264.photobucket.com/albums/ii176/necrombi/NEO/2.png]
    Does anyone know how to solve this?
    Edited by: 864451 on Jun 8, 2011 5:11 AM

    Hi, thanks for your reply.
    I implemented Time dimension with your recommend, and have time dimension like this:
    Time Hierarchy: Total > Year > Quarter > Month > Day
    Year:
    Primary key: Calendar_year_start_date
    Chronological key: Calendar_year_start_date
    Quarter:
    Primary key: Calendar_quarter_start_date
    Chronological key: Calendar_quarter_start_date
    Month:
    Primary key: Calendar_month_start_date
    Chronological key: Calendar_month_start_date
    Day:
    Primary key: Day
    Chronological key: Dimension_key
    And Ago function works fine with month level: AGO(expression, mywh.D_qn_thoigianDim."month", n)
    But return sum result of 12 month with: AGO(expression, mywh.D_qn_thoigianDim."year", 1)
    In my case, i just use AGO(expression, mywh.D_qn_thoigianDim."month", 12) to get year ago value. But i still don't understand clearly about OBIEE Time Serries functions.
    Thanks,
    Dung Nguyen

  • Just updated to 10.9.2 and my function keys won't work and mouse won't scroll!

    Updated to OS X 10.9.2 last night and my function keys wont work today. the brightness keys do nothing and my volume keys jump to desktop and  the calendar display. My mouse has also stopped scrolling. I have looked in system settings > Keyboard but there doesnt seem to be any answers.
    Help much appriciated

    Hello Yeomans7,
    Thank you for using Apple Support Communities.
    For more information, take a look at:
    Intel-based Macs: Resetting the System Management Controller (SMC)
    http://support.apple.com/kb/ht3964
    Have a nice day,
    Mario

  • Default Administrator password in BI Administration Tool - Security Manager

    Hello all,
    I'm new to OBIEE and have recently been playing around in the BI Administration Tool to create my own repository (.rpd) metadata files from demo DBs. I selected "Manage" -> "Security" to open Security Manager and then set a logging level of 2 on the Administrator user.
    UNFORTUNATELY, there is a default password that apparently gets specified that I didn't notice, so when I closed my repository file and tried to re-open it, it is now challenging me for a password that I didn't set, don't know, and have not been able to find in documentation or posted threads anywhere.
    Has anyone else ever come across this problem before or know the default password? Any help would be greatly appreciated. Thanks guys.

    Guys,
    First, let me thank you all for you quick responses and willingness to give me a hand. It's greatly appreciated. And thanks Ally for noticing the name! Glad you liked it. :)
    Unfortunately, my problem still exists. None of the following passwords worked for me: <blank>, "Administrator", "administrator", or "ADMINISTRATOR".
    Also, I should clarify for the thread that I'm not using Paint.rpd or SH.rpd; I'm creating my own repository from scratch. For those who read this post and have literally 90 seconds to spare, I would ask you to try and recreate this same thing with me and see if it's just me (and if I'm crazy):
    1) Open OBI Administration Tool
    2) DO NOT open an existing repository, create a new one. Name it whatever; mine is the default "Metadata1.rpd"
    3) Don't bother adding any metadata to it, go immediately to "Manage" --> "Security" --> "Users" and open up the Administrator user by double-clicking it.
    4) Notice there is a "Password" and "Confirm Password" value already defined by default! DON'T change it (this is the password in question that I accidentally accepted). Just click the "OK" button without making any changes to that form.
    5) Save, close, and then try to re-open this repository you just created. It should be challenging you for a password now, right? And I bet it will not accept <blank> or any variation of "Administrator".
    Believe me, I know better now in the future to not let this happen. But I can't for the life of me figure out this password that was automatically populated and WHY there would be one there in the first place! I was walking through a lab that told me to open this security setting for Administrator to set a logging level, but it did not mention anything about a setting a password. So, I created a repository that I have now magically locked myself out of. :)
    Can anyone else please try to recreate this and let me know if it's just me or not? I am using BI Administration Tool version: 10.1.3.3.2.071217.1900.
    Thanks again guys.

  • Remote Server Administration Tools for Windows 10 Technical Preview Not installing

    When i try and install the remote server administration tools for windows 10 on my windows 10 technical preview install i get this error
    Any ideas why this is happening? when i'm installing the correct version for windows 10
    http://www.microsoft.com/en-us/download/details.aspx?id=44280

    On Thu, 12 Feb 2015 07:33:29 +0000, samfty wrote:
    Any ideas why this is happening? when i'm installing the correct version for windows 10
    If you're running 9926 then you're not installing the correct version. If
    you expand the Details section you'll see that version was published last
    October. You'll need this one, which was published in at the end of
    January:
    http://www.microsoft.com/en-us/download/details.aspx?id=45520
    Paul Adare - FIM CM MVP
    Q. How do you solve bus problems?
    A. Shoot the driver.

  • Ago and Todate functions very slow

    I have been playing around with the Ago and Todate functions in BI EE (based on data from the Global schema which I imported into BI EE Administrator) but I find these functions very slow to return the data in an Answers report. Has anyone else found this?

    What's the size of the data set?
    Yes, I'm currently experiencing it. Running on a 600-700k rows tables...
    However, there're 2 things that might help:
    a) we're doing development with cache off - enabling cache - makes report come instantly...
    b) make sure the metrics have correct levels set up - i.e. it's sometimes advantageous to have several duplicates of 1 metric just for this purpose...with different levels....
    Please let me know if you find other ways to improve performance...

Maybe you are looking for