Calculation of KFs at query run-time based on Characteritics Drill-down

Hello All,
I have an Important Issue which I need to solve but got stuck.
The report requirement is that we need calculate the KF values based on the drill-down selection in the report at run-time.
Say for eg: if the user is drilling-down the report by customer, plant or company code or any thing else other than material group...we need to calculate / Include KF values for only Materail Group  = "A" and if we are at the materail group level we need to calculate all the material groups which includes A, B, T and so on.
Please suggest what are the avialable options for me like using virtual key figures. please provide me with some sample codes.
your help will be highly appricated.
thanks,
Pra

any toughts....Pra

Similar Messages

  • To find Query Run-times

    Hi guys,
    i was trying to compare query run-times with and without BIA using RSRT, however i'm running into hurdles..
    the same query when executed twice (without BIA) without using cache is showing different data manager times
    i'm surprised how the reason could be
    the difference sometimes is very high even the wait times are also sometimes very different
    how to arrive at the average run-times are there any tools besides rsrt (i hve no access to statistics queries) but st03 doesnt seem to be of much help
    i'm lookin at the fine difference so accurate times are necessary
    thanks,
    your help will be greatly appreciated

    Hi.....
    check the following links :
    http://help.sap.com/saphelp_nw04s/helpdata/en/43/e3807a6df402d3e10000000a1553f7/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/7c/2bde42fa712b78e10000000a155106/frameset.htm
    Another thing :
    If you want to use the BI statistics for Query runtimes, you will need the 0TCT_C01 InfoCube, together with the multiprovider 0TCT_MC01.
    The queries for the BI statistics to report over query runtimes are all built on the multiprovider.
    Besides that, you will need the virtual infoprovider 0TCT_VC01, to be able to report on the latest data. Because you will probably load the statistics each night into the 0TCT_C01 cube, you can report on the latest data using the 0TCT_VC01 virtual cube.
    Hope this helps you........
    Regards,
    Debjani.........
    Edited by: Debjani  Mukherjee on Sep 13, 2008 8:01 AM

  • Manage query - run time errors

    Hi,
    we have one user working at one desktop which receives error "run-time error 5" followed by "401 Automation error" when selecting the manage query wizard proceeding from the BPC Excel action pane.
    We only have this at one desktop. Any ideas?
    Dries

    Hi,
    You can check the query run time by using T code RSRT.
    1. Go to T code RSRT
    2. Give your query name.
    3. Click on the "Execute + Debug" tab
    4. Various check boxed for Debug options will appear on the screen
    5. Under the "Others" node you will find the check box for "Display Statics Data"
    6. Check this check box and click on continue.
    7. This will execute the query and provide you selection screen if any.
    8. Once the query is completely executed, click on "back" button or simply hit F3.
    9. This takes you to the "Statistic Data for Query Runtime screen"
    10. Here you can take the total of "Duration" column to get the total duration for query execution.
    Please refer following link for details:
    [http://help.sap.com/saphelp_nw70/helpdata/en/43/e3807a6df402d3e10000000a1553f7/frameset.htm]
    Hope this answers your query.
    - Geetanjali

  • Query running time

    Hai,
    I am new to Oracle. How to find the query running time in SQL plus.
    Edited by: user12283394 on Dec 20, 2009 10:33 PM

    SQL> set line 2000;
    SQL> set timing on;
    SQL> select instance_name
    2 from V$instance;
    INSTANCE_NAME
    syslog
    Elapsed: 00:00:00.03
    SQL>
    Regards
    Asif Kabir

  • How to measure query run time and mnitor performance

    Hai All,
                   A simple question. How to measure query run time and mnitor performance? I want to see the parameters like how long it took to execute, how much space it took etc.
    Thank you.

    hi,
    some ways
    1. use transaction st03, expert mode.
    2. tables rsddstat*
    3. install bw statistics (technical content)
    there are docs on this, also bi knowledge performance center.
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/cccad390-0201-0010-5093-fd9ec8157802
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/3f66ba90-0201-0010-ac8d-b61d8fd9abe9
    BW Performance Tuning Knowledge Center - SAP Developer Network (SDN)
    Business Intelligence Performance Tuning [original link is broken]
    also take a look
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/cccad390-0201-0010-5093-fd9ec8157802
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/ce7fb368-0601-0010-64ba-fadc985a1f94
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/c8c4d794-0501-0010-a693-918a17e663cc
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/31b6b490-0201-0010-e4b6-a1523327025e
    Prakash's weblog on this topic..
    /people/prakash.darji/blog/2006/01/27/query-creation-checklist
    /people/prakash.darji/blog/2006/01/26/query-optimization
    oss note
    557870 'FAQ BW Query Performance'
    and 567746 'Composite note BW 3.x performance Query and Web'.

  • Alert with Query does not have orange navigation / drill down arrows

    Hi Experts!
    My Alert which uses a Query doesn't allow me to drill down into the document (Sales Order) .  The Query for this alert is:
    SELECT T0.[DocNum], T0.[CardName], T0.[DocDueDate] 'Due Date', T2.[TrnspName],  T0.[U_PostCode], T1.[SlpName] FROM ORDR T0  INNER JOIN OSLP T1 ON T0.SlpCode = T1.SlpCode INNER JOIN OSHP T2 ON T0.TrnspCode = T2.TrnspCode INNER JOIN RDR1 T3 ON T0.DocEntry = T3.DocEntry WHERE T0.[CANCELED] = 'n' and  T1.[SlpCode] IN ('3', '4', '5', '6', '7', '8', '9', '17', '21', '29', '39') and T0.Address2 NOT LIKE '%'T0.U_Postcode'%' and   T3.[LineStatus]  = 'o' and T2.[TrnspName] Like '%%del%%' GROUP BY T0.[DocNum], T0.[CardName], T0.[DocDueDate] , T2.[TrnspName],  T0.[U_PostCode], T1.[SlpName] for browse
    Please can you help me on this?
    Many thanks,
    Caroline

    Hi Caroline,
    Try not to "group by" a query for alert with drill down.
    Cheers

  • Webi report on OLAP Bex query -  Cost element Hierarchy not working Drill down

    Hello,
    We have a BO report on Bex query, Not on universe, we have a Hierarchy for Cost Element Group, and we are expecting the Drill down functionality for that in BO report, but it does not.
    Webi report on OLAP Bex query -  Cost element Hierarchy not working Drill down
    Any pointers how to do it please
    Thanks
    Krishna

    Hi,
    WebI reports on BEx source don't use same Drill feature as other sources, it's replaced by expland/collapse of hierarchy nodes (documented in WebI user guide in § "24.1 Drill defined"). This means you have to create query which selects all hierarchy sub-tree you plan on exploring later in report, otherwise if no data is available under a node there will be no '+/-' sign to visit this part of tree.
    You could try first to select "All members" from hierarchy in QueryPanel and see if behavior in report suits your needs. Then you should restrict hierarchy member selection to what's really needed to avoid performance issues.
    Regards,
    Loic

  • Displaying different sheets at run time based on value of the parameter

    Hi,
    I've a query regarding displaying two different sheets at run time in Oracle discoverer based on the value of the parameter that i give.
    I've a parameter Summary_flag.
    If the value of the parameter is 'Y',then it should display a sheet,say for example it should display Sheet1.
    If the value is 'N',then it should display another sheet, say for example it should display Sheet2.
    Is there any way in which i can accomplish this?
    I went through the Format and Tools menus but couldnt find anything regarding this aspect.
    Can you help me out?
    Thanks,

    Having a Disco parameter dictate which worksheet is displayed is not an option that is available. There are a few workarounds, though:
    1. Have a portlet (or some other web interface) accept your parameters, and then call the appropriate worksheet.
    2. Have 2 worksheets, and have it devolve into a training issue (for a summary run this, for all the details run this).
    3. Create calculations that will show or hide column data depending on the parameter selected - the columns will still be there, and you can fill them in with blanks, or a message like "N/A for Summary".
    4. Create a report that will allow the users to drill between the summary and detail data - I'm not sure whether you could use a parameter to then say whether the report should open up summarized or expanded.

  • To optimize query run-time

    Hi,
    I have an sql query that access a single table which contains approx. 10 million records. The table has 4 columns (there are no indexes defined for the columns), which are 'new_id', 'time', 'access_code' and 'graph_qty'. With time being defined in 'dd-mm-yyyy hh:mm:ss'. The idea is to scan the table to retrieve records whose 'time' and whose 'access_code' match with the condition in the where-clause and then de-normalize these records based on the 'access_code'. The resultant set would have records wherein 'access_code' is denormalized into columns, with each 'access_code' having a unique column.
    The query runs for about 30mins.
    /* '&¤t_date' is a pre-defined variable containing a date (assume sysdate)*/
    SELECT
    new_id
    , trunc(time) AS time
    , SUM(CASE WHEN access_code = '100' THEN graph_qty END ) AS graph_1
    , SUM(CASE WHEN access_code = '200' THEN graph_qty END ) AS graph_2
    , SUM(CASE WHEN access_code = '300' THEN graph_qty END ) AS graph_3
    , SUM(CASE WHEN access_code = '400' THEN graph_qty END ) AS graph_4
    , SUM(CASE WHEN access_code = '500' THEN graph_qty END ) AS graph_5
    , SUM(CASE WHEN access_code = '600' THEN graph_qty END ) AS graph_6
    , SUM(CASE WHEN access_code = '700' THEN graph_qty END ) AS graph_7
    , SUM(CASE WHEN access_code = '800' THEN graph_qty END ) AS graph_8
    , SUM(CASE WHEN access_code = '900' THEN graph_qty END ) AS graph_9
    , SUM(CASE WHEN access_code = '1000' THEN graph_qty END ) AS graph_10
    FROM
    dummy_table
    WHERE trunc(time) IN ( '&¤t_date'
    , ADD_MONTHS('&¤t_date',-1)
    , ADD_MONTHS('&¤t_date',-3)
    , ADD_MONTHS('&¤t_date',-6)
    , ADD_MONTHS('&¤t_date',-12)
    , ADD_MONTHS('&¤t_date',-13)
    , ADD_MONTHS('&¤t_date',-15)
    , ADD_MONTHS('&¤t_date',-18)
    , ADD_MONTHS('&¤t_date',-24)
    AND access_code IN ('100','200','300','400','500','600','700','800','900','1000')
    GROUP BY
    new_id
    , time
    Please suggest ways to reduce the qry run-time.
    Thanks,
    kartik

    does this 20min include the time to display the data?
    how long much does it take to execute the following queries?
    select /*+ full(t) */ count(*) from dummy_table t;
    select count(*) from(
    SELECT
    new_id
    , trunc(time) AS time
    , SUM(CASE WHEN access_code = '100' THEN graph_qty END ) AS graph_1
    , SUM(CASE WHEN access_code = '200' THEN graph_qty END ) AS graph_2
    , SUM(CASE WHEN access_code = '300' THEN graph_qty END ) AS graph_3
    , SUM(CASE WHEN access_code = '400' THEN graph_qty END ) AS graph_4
    , SUM(CASE WHEN access_code = '500' THEN graph_qty END ) AS graph_5
    , SUM(CASE WHEN access_code = '600' THEN graph_qty END ) AS graph_6
    , SUM(CASE WHEN access_code = '700' THEN graph_qty END ) AS graph_7
    , SUM(CASE WHEN access_code = '800' THEN graph_qty END ) AS graph_8
    , SUM(CASE WHEN access_code = '900' THEN graph_qty END ) AS graph_9
    , SUM(CASE WHEN access_code = '1000' THEN graph_qty END ) AS graph_10
    FROM
    dummy_table
    WHERE trunc(time) IN ( '&¤t_date'
    , ADD_MONTHS('&¤t_date',-1)
    , ADD_MONTHS('&¤t_date',-3)
    , ADD_MONTHS('&¤t_date',-6)
    , ADD_MONTHS('&¤t_date',-12)
    , ADD_MONTHS('&¤t_date',-13)
    , ADD_MONTHS('&¤t_date',-15)
    , ADD_MONTHS('&¤t_date',-18)
    , ADD_MONTHS('&¤t_date',-24)
    AND access_code IN ('100','200','300','400','500','600','700','800','900','1000')
    select count(*) from(
    SELECT
    new_id
    , trunc(time) AS time
    , SUM(CASE WHEN access_code = '100' THEN graph_qty END ) AS graph_1
    , SUM(CASE WHEN access_code = '200' THEN graph_qty END ) AS graph_2
    , SUM(CASE WHEN access_code = '300' THEN graph_qty END ) AS graph_3
    , SUM(CASE WHEN access_code = '400' THEN graph_qty END ) AS graph_4
    , SUM(CASE WHEN access_code = '500' THEN graph_qty END ) AS graph_5
    , SUM(CASE WHEN access_code = '600' THEN graph_qty END ) AS graph_6
    , SUM(CASE WHEN access_code = '700' THEN graph_qty END ) AS graph_7
    , SUM(CASE WHEN access_code = '800' THEN graph_qty END ) AS graph_8
    , SUM(CASE WHEN access_code = '900' THEN graph_qty END ) AS graph_9
    , SUM(CASE WHEN access_code = '1000' THEN graph_qty END ) AS graph_10
    FROM
    dummy_table
    WHERE trunc(time) IN ( '&¤t_date'
    , ADD_MONTHS('&¤t_date',-1)
    , ADD_MONTHS('&¤t_date',-3)
    , ADD_MONTHS('&¤t_date',-6)
    , ADD_MONTHS('&¤t_date',-12)
    , ADD_MONTHS('&¤t_date',-13)
    , ADD_MONTHS('&¤t_date',-15)
    , ADD_MONTHS('&¤t_date',-18)
    , ADD_MONTHS('&¤t_date',-24)
    AND access_code IN ('100','200','300','400','500','600','700','800','900','1000')
    GROUP BY
    new_id
    , time

  • Query Run time

    Hi good mOrning everybody.
    I am facing a problem regarding calculation of query runtime . From the time query is fired till the result comes in the Excel file . Is there any automated process to calculate ? If so please help me out.
    Can anybody please help me out ?

    Hi,
    Go To Transaction: ST03 on left hand side u can find Administrator, click the drop down and select Expert mode
    On the same left side you can find BW system load ,here you can find all the queries and their individual time of execution.
    To know query execution time for a particualr set of selection criteria, you can use the RSRT option in debug mode
    suresh

  • Unable to Create Query - Run Time Error

    Hi All,
    I'm try to create a query from a Cube .... the moment I drag 0CALMONTH and restrict it to Varaible Last Year This Month. I receive, the following error "Run Time Error 2147417848 (80010108) ....Automation Error. The Object Invoked has disconnected from its client.
    When I check with Event Viewer : The following message appear " ID: 1, Application Name: Microsoft Office Excel, Application Version: 12.0.6324.5001, Microsoft Office Version: 12.0.6215.1000. This session lasted 1784 seconds with 780 seconds of active time.  This session ended with a crash."
    I'm running Ms Vista Enterprise OS with Office 2007.
    Please advise
    TQ
    Nathan

    Hi,
         Actually this is a frontend error.
    Check the SAP Note Number: 1039191
    Download the DLL.
    Problem Description: There is a BI bug when we use BW3.5 frontend tool with BI7 datawarehouse workbench.
    Symptoms: When you try to restrict an object in Query designer, it will greayed out by giving runtime error.
    Solution: Take a backup of wdbspres.dll file which is present under C:\Program Files\SAP\FrontEnd\SAPgui. Copy the original
    file with this new file available in project filder. Problem will be resolved.
    Regards
    Karthik

  • Query run time increases with subsequent runs.

    Hello All
    I am looking for some hint about if someone else has faced such an issue in OBIEE
    We are trying to enhance performance of some OBIEE Analysis reports. Every time we do a change and deploy out changes the report runs very quick like in 40 seconds . Even when I run the physical query in the database it runs quick as well. After few minutes we run the report again it take 10 minutes and then after some time we run it again it takes 20 minutes. It stabilized around 30 minutes.
    We thought it needs more tuning. We tried some more, removed outer joins from the RPD, tuned those joins where we are fectching large amounts of data and deployed it again. Again the first time we ran the report it returned results in less than 30 seconds. Ran it again and it took 6 minutes. And again around 9 mins.
    Once again the physical SQL is quick too in the database.
    The first time we run the report we are happy to see the run time but subsequent runs take so long.
    This is a test envt. so there are not huge load on the database. Also currently we dont have any caching enabled but we may do that as well.
    I am just curious to see if anyone has faced something like this. I am running out of options on further tuning the views and joins that we are using.  I am not able to think, why the first time we check our reports they run fast and this behavior is so reproducible now.  And every time we start with our changes we delete all presentation layer cache etc.
    Thanks

    query caching is primarily a run-time performance improvement capability.and over a period of time, performance tends to improve due to cache hits for more refer this Managing Performance Tuning and Query Caching - 11g Release 1 (11.1.1)

  • How to get value in data control at run time based on bind variable in VO

    Hi,
    we are capturing the value of customer id at run time. we are associating the captured value of customer id to bind variable of the view object.
    View object is returning the data of that customer id, this view object is part of the application module ,this application module is exposed as data control,so than we have drag and drop this view object response on the
    page from data control.
    How ever after assigning the customer id to bind variable but still it is not showing on jsf page,even we refreshed the data control manually with the help of java code so kindly provide some solution for it.

    Hi,
    If i got your post correctly,you can filter your VO using defining view criteria see following samples
    Oracle ADF - Create View Criteria and Execute using Bean.
    http://adf-lk.blogspot.com/2011/05/oracle-adf-create-view-criteria-and_4727.html

  • Key Figure values based on characteristic Drill-downs

    Hello All,
    I have Issue with my drilldown options in the report. The values of Sales qty need to change at particular drilldown.
    I have Sales Revenue and Sales QTY key figures in my DSO with  plant, factory, customer and Business type (Values A, B, C and D) characteristics.
    IN the report requirement I want to show the SALES QTY for only Business Type  "A" at Plant , factory and customer level, but when I am at the Business code level, then I am to show all the quantities by that level.
    THe sales revenue should always show values for all Business code irrespective of the drilldowns.
    please provide suggestions and code on how to go about the issue.
    thanks,
    pra.

    Hello Guys,
    Thanks for your response.
    Let me explain clearly...with an example.
    We have DSO which has 5 chars and 2 KFs.
    Chars - Company Code, Plant, Customer, Material and Business Code (which has values A, B and T).
    KFs - Sales Qty and Sales Revenue.
    Report output ---
    Customer
    Company Code
    Plant
    Material
    Business Code
    Sales Qty and Sales Rev
    Requirement is a follows -
    When the report is run.... the report will display on Customer with KFs.
    then if user wants to pull company code he can do so...as will other chars (Plant, Material and Business Code)
    but the condition is that when the user is seeing the report at customer with KFs ,....the KFs should only show values where business code = "A"
    so is the same with other chars - Company code, Plant and Material.
    But when user drags and drops the Business Code char in the report against the KFs .then the report should include all Business Codes ( A, B and T) with corresponding sales qty and sales rev for all business codes.
    Solution - Partially working--
    What I have done..is restricted the sales qty and rev with Business code = A, its working fine for all drill downs except that, when I am at business code level its showing as
    Business Code QTY REV
    A             300          3000
    B                0              00
    T                0               00 .
    Hope you got the issue. Please let me ,,if you need any information.
    Thanks,
    Pra

  • APEX... query run time

    Hi,
    My report is based on a view which holds apprx 15 million rows and 15- 20 columns... it is currently taking almost a mint to two to pull the data... May I know if there is a faster way to pull this info...?
    Thanks again in advance

    Hi user9231694
    Please change your username to something a bit more meaningful - this is a friendly forum!
    You should also read this...
    [http://tkyte.blogspot.com/2005/06/how-to-ask-questions.html]
    You need to provide more information when your asking questions so that we can help. For instance, have you run the query outside of apex to see how long is takes, have you looked at the explain plan, can you post the query and explain plan etc etc?
    Cheers
    Ben

Maybe you are looking for