Skip to Content
author's profile photo Former Member
Former Member

Display keyfigure based on drilldown characteristics

Hello Experts!

I need some help from expert BE query writers. I have to create a query for asset management, where useful life of the asset is one of the key figures. But this field is valid only if the query is drilldown by asset number, otherwise, by default the value is summarized and does not give useful result.

So, what I want is if the query has asset number in the drilldown, then only show the useful life key figure, otherwise, hide this key figure from the report. If I cannot hide it completely, then at least do not display any value for this key figure until asset number is added to the drilldown.

I would like handle this situation from query side, if possible. Is there any way I can hide the key figure or do not summarize it unless drilldown by asset number is added?

Any help would be greatly appreciated!

Thanks,

Archana.

Example format

Query1:

If drilldown by asset:

Asset Number, Userful life, Key fig2, Key fig3

No drilldown:

Key fig2, key fig3

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Best Answer
    Posted on Nov 05, 2009 at 01:28 PM

    Hi,

    if i did understand you correctly you like to show your key figure "useful life" only in combination with the asset number, otherwise it should be zero, or better the column wouldn´t appear, right?

    Just try to realize it by that way:

    1) Build up a formula variable which reads the characteristic value for your asset number. (replacing variable by info object). Check this formula - by drill down on the "asset level" you should see the number, otherwise a zero or the "red X". Eventually you´ve got to add the data function "NoErr(x)" into that formula.

    2)Build a second formula which proves if the first one is filled with a number or not by a boolean operator. (e.g. first formula not equal zero). Multiply the boolean operator with your key figure "useful life". If you are on asset level, you should get your result, otherwise a zero.

    3)Switch off showing zero in colums.

    4)If it all works correctly, hide the first formula.

    Hope this could help you.

    Greetings,

    Olaf

    Edited by: Olaf Neubert on Nov 5, 2009 2:28 PM

    Edited by: Olaf Neubert on Nov 5, 2009 2:29 PM

    Edited by: Olaf Neubert on Nov 5, 2009 2:29 PM

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 05, 2009 at 12:47 AM

    Hi Archana,

    I can think of at least two ways to achieve this:

    1) At query level:

    Use BADI RSR_OLAP_BADI to zero-out the unwanted Key Figure if the characteristic is not in the drilldown. In the COMPUTE method of the BADI, you can detect if the characteristic is in the drilldown by looking at the characteristic values in table C_S_DATA. The value shouldn't be there if the characteristic is not in the drilldown.

    Note: Make sure you use the structure I_S_RKB1D to determine if it's your query that's being executed

    2) At web template level:

    This can be achieved by JavaScript that detects the presence of the Characteristic in the Anaylsis Table (e.g either by reading values from an XML DataProvider or by looking at the column names currently in the table). You can then hide the KF using JavaScript again (using the Command API).

    Hope this helps.

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Emmanual,

      Thanks for your reply! Sorry but I am not an expert BW query writer. I currently have access only to query writing. How do I use BADI as you suggested? Somewhere through query design? I do want to execute the query from Bex, Excel tool.

      Thanks,

      Archana

      (PS: Sorry for the typo in my original post - I meant BW and not BE)

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.