Sort Key Figure in a Query

I have a situation where I have to use a query (not possible to use a view - long story, but limitations on views make it so)
I have a simple query that has products on rows, and Month and Sales Value on the columns.
I want to sort the Sales value descending.
ie
product   Sales Value/8.2005
prod1      500
prod2      400
prod3      300
How do I tell the query to sort on the Key figure value descending as shown above???
I have managed to achieve this by putting a condition on that returns the top 100% of the query, however there must be a better way??? (although I am slowly losing confidence in SAP's thinking (or lack thereof))
Thanks in advance for any assistance.
Regards
Richard

Hi JKyle,
Thanks for your response.
I am aware that you could sort by using the Properties on the context menu of the key figure, but this is no good for a default view without hacking the URL, which becomes quite tedious. (My users are not capable of entering even the simplest of variables, let alone using a context menu to sort every time they run a report.
You can also bookmark once it has been sorted, however have had problems with bookmarks disappearing in the past, and so I don't really consider this to be a solution either.
I guess I thought that this was such a fundamental requirement that it would be included, and that I was missing some setting somewhere when developing the query.
Thanks again for your response.

Similar Messages

  • Problem with virtual Key Figure in a query

    Hi Experts,
    I would like to share my problem with the virtual key figure in a query:
    I have a query with a virtual key figure and when I eject the query by analyzer, the result sometimes is displayed and sometimes is not displayed (is equal to 0), with the same initials values. And when I eject the query by RSRT always display the result for the virtual key figure.
    Why don't always display the result?
    Thanks a lot

    Hi,
    I think that the problem is the level of support package. We have BI AddOn 7.X (based on 7.20) support package 0.
    What do you think?
    Regards

  • Changing the formula to a key figure on a query

    Hello All,
    I do not have access to BEx. I would please like to know how to change the formula to a key figure "Total $" in a QD Promo Analysis query (technical name - N03_Q_D_N03_SD_502_0003). Will transaction RSRT take me to the query and eventually the formula so I can change it? If so please give me guidance as this is the first time I go into transaction RSRT. If there is another way please also give guidance.
    Thank you and kind regards
    Keith Kibuuka

    Hi Vishvesh,
    Thank you for your response. Maybe access to BEx was the wrong word - I do have access although I was trying to avoid configuring the SAP logon to add this particular client onto because I have not done this before. My boss has helped me and I have now have "access".
    Therefore from the query designer can you please guide me on how to change the formula to a key figure on a query? Input from all people is also be very much appreciated.
    Thank you and kind regards,
    Keith

  • How to sort key figures

    Hi Gurus,
    Thanks in Advance...........
    How to sort key figures & Way to find out customers with 0 sales.
    Thanks,
    Venkat.

    Hi Rakesh,
    Thanks for your info, i assigned point to you.
    any idea on Way to find out customers with 0 sales....
    Thanks,
    Venkat.

  • Key Figure Calculation in Query

    Gurus,
    How do i calcculate below  in query  basically i have 3 KF as dates below and want a CKF or formula variable
    which calculates A - (IF B Not Empty then take B  or else take C.)
    Z = A - if (B != " '', B, C)
    A = Key Figure
    B = Key Figure
    C = Key Figure
    thanks

    HI Zuben,
    To acheive this
    calculates A - (IF B Not Empty then take B or else take C.)
    Z = A - if (B != " '', B, C)
    A = Key Figure
    B = Key Figure
    C = Key Figure
    Try this !!!!!!!
    If u create a  CKF,u will have operators in it,in that choose Boolean Operators,again in that chose
    1)is not equal to
    and
    2)Equal to.
    for ur calculations.
    Z= Calculated Key Figure.
    Z= A - (B NE 0)B + ( B EQ 0)C
    Case One -- B NE 0
    Z= A-(1 * B)+0
    Z = A-B
    Case Two -- B EQ 0
    Z= A-(0 * B)+(1*C)
    Z = A-C
    I guess this is your requirement.
    Rgds
    SVU

  • Exception color can not display at another key figure in BEx query desinger

    I have a report requirement, the user want to display the average price on each month ,such as:
    Jan.   Feb. Mar.  Apr. etc.
    100    105    104   95   ....
    and the user want to compare each other months with Jan's price.
    they want to display the exception color when the rise or down rate greater or less than 5%.
    Now ,I can only change the output structure such as:
    Jan.  Feb. Rate2-1                 Mar.  Rate3-1                 etc.
    100   105   (105-100)/100=5%  104    (104-100)/100=4%  ....
    Now I can set Exception on the formula Rate2-1 Rate3-1....
    But the Exception color can only display on Rate2-1,Rate3-1...
    and Not the Keyfigure Feb. Mar...
    I am using the BI 7.0 and the new Query Designer.
    Who can help me to solve this question .
    Thanks.
    Yours Youming.Zhao

    Hi,
    its simply not supported for BEx Analyzer. Exception reporting on another key figure is only possible for Web Reporting.
    Check this actual SAP Help Link:
    [Restrictions in the BEx Analyzer|http://help.sap.com/saphelp_nw70/helpdata/en/45/5038f28cce08d2e10000000a11466f/content.htm]
    Sorry that i dont have a better answer
    Cheers

  • Convert characteristic values in key figures in a query

    Hello all,
    i have a query which provides some key figures and also some probabilties (defined as characteristics). I want to multiplicate the probabilities with the key figures and therefore I need to convert the characteristic values for the different probabilities in key figures.
    What is the best wys to do this.
    Any help would be great.
    Best Regards,
    Stefan from Munich/Germany

    Stefan,
    You need to create a formula variable of your characteristic.
    In the Create Formula screen right mouse click on Formula Variable and go through the create process.
    The characteristic needs to stay in your query (you can change it's display to No Display) to pass it's value to the formula.
    Once you have done this you can use the formula Variable in any other formula.
    Regards
    Gill

  • Number of key Figures used in Query

    Hi,
    I would like to know the number of queries in a Query,
    Is there any way to find out this?
    We have nearly 100 queries, and we were asked to find out the top 5 queries in terms of number of key figures.
    Thx.

    Hi Thejo,
    There is no direct way to do this using another BW query simply because the data is not stored in either Masterdata Info Objects/CUBE ODS. They are stored in BW system tables which are not directly accesible by any queries to build using the Query Builder.
    Try to locate the system table that holds these Info (Keyfigures + Query Name) and do ABAP Query instead.
    Regards,
    Jkyle

  • Lock key figure with a query

    Hi BW gurus,
    I have created a calculate key figure 'CKF1' in the development system and added to a query 'Q1'. The same calculated key figure is presnt in the production system and is being used by some queries.
    As we know that BW handles the duplicate calculate key figures on its own. However, to transport Q1 and CFK1, the system requires that SFK1 should be locked by/for Q1. I need help in doing that.
    One liner: How to lock CKF1 with Q1?
    Thanks.

    Hi Anooj,
    this is my understanding :: u made  ckf1 as global.if u make it as a local  then other queries can't use this.
    regards
    sridhar

  • Key Figure Restrictions in Query

    Hi all,
    I've got this scenario on hand:
    I want to display a Bex report with the a particular key figure (Actuals) restricted to only specific value COMBINATIONS of two characteristics (Cost Centre and Cost Element). i.e. The restrictions should only apply for each individual combination of the characteristics (e.g for Cost centre = S0561 and Cost Element = 70400 , another combination could be for Cost Centre = S0352 and Cost Element = 70610 ).
    The challenge here is that if you restrict the key figure based on the individual characteristics (say, for Cost Centre = S0561 , S0352 and for Cost Element = 70400 , 70610) then it blocks off other figures from characteristic combinations that are should be allowed (e.g. Cost centre = S0561 and Cost Element = 70610 ,  and another combination of Cost Centre = S0352 and Cost Element = 70400).
    Any suggestions on how to handle this, typically from a previous experience, will be appreciated.
    Regards,
    Uche

    Hi Uche,
    A workaround for this scenario would be to include a hidden keyfigure for every characteristic combination. (If there are not many combinations)
    For e.g.
    Hidden KF1  Restricted on Cost centre = S0561 and Cost Element = 70400
    Hidden KF2  Restricted on Cost Centre = S0352 and Cost Element = 70610
    Then another final key figure, which is visible and is a formula KF
    Actuals     Formula = Hidden KF1 + Hidden KF2 + ..
    Best Regards,
    Dabre

  • Benchmarking Key Figures in a query which is posted in a web template.

    Hi All,
    has someone experiences with benchmarking in a query?
    What possibilitys do we have?
    We want to show the following:
    The query has in the rows the characteristic "sector" and in the collumns several figures. We navigate in this report via "filter and drilldown according to" to the next lower level. What we want to show is a benchmark of the figures of the lower level to the result of the first level. Example: The result of "sector1" is 150, "sector2 100" and so on and we navigate from sector1 to the belonging lower level "segment A, B, C, D". Now we want to see the information of the result of the filtered sector (150) as a benchmark to the associated segments A, B, C, D.
    I know it is a bit complicated but perhaps someone has a good idea for a solution?
    Regards
    Mirjam

    Have you found the solution? I have a similar kind of requirement.

  • Problem in display of char. and key figure for yearly query

    Hello all,
    I got a query in which i have to do restriction on
    Calendar Day/Month in Rows under Material which is a Characteristics
    So it should be
                                                               PACKAGE QUANTITY
                                            JAN  FEB  MAR   APRIL.......DEC
    PACK1
    PACK2
    PACK3
    PACK4 for current year
    PACK4 for prior YEar
    Now the months display is not pre decided, it can be anything as per the input of user.
    So i have to restrict it on Calendar month for Material twice
    In current year , just introducing the Interval range variable
    In previous year, same restricition with offset -12
    Now the problem is while displaying it shows
                                           JAN'06 JAN'07  FEB'06 FEB'07  MAR'06 MAR'07........ 
    PACK1
    PACK2
    PACK3
    PACK4 for current year
    PACK4 for prior YEar
    Which is not desirable.
    I only want value for Jan in one column
    and for previous year and current year in different rows thats it.
    If i remove Calendar year/month from columns there is no way I CAN DISPLAY MONTHS .
    How to achieve this.
    Please suggest.

    Kartikey,
    Rusty's suggestion wont work - using two characteristics for year and month will have the same effect as the position you are in at the moment.
    ie..
    2007     Jan.07     Feb.07    Mar.07   Apr.07
    2006 -
    Jan 06  Feb 06  Mar 06
    If you have the posting period of 01 - 02 - 03  (just the period number only, no year) then your query will display
    2007-01-02-03-04
    2006-01-02-03-04
    Regards
    Gill

  • Sorting a Key Figure by default in a query

    Hi,
    I'm trying to set up a query with a key figure that is sorted in descending order by default everytime.  I tried creating the following condition:
    Key Figure - Sales Volume
    Operator - Top %
    Values - 100
    This sorts the key figure in descending order to a point.  When I add a characteristic to the report (for example, sold to), the sorting is no longer active.  I would like this key figure to remain sorted in descending order regardless of the any manipulation to the report.  But, I'd still like the user to have the ability to change the sorting if they want to sort by another key figure (ascending or descending)
    I'm using the BI 7.0 Query Designer.
    Thanks!!

    Check this:
    Sort Key Figures and Maximum query result
    Organising key figures in BEx Query Designer
    ordering display in a KF
    Hope it helps..

  • Sorting by Key figure

    Hi Guys
    How can I sort the query by a key figure or calculated key figure when I run the query, I know I can do it by rigth click on the key figure after the query is executed but I want the query to be sorted by the key figure as soon is executed.
    Thanks
    Edited by: Antonio Rodriguez on Jul 2, 2008 11:20 PM

    Antonio,
    Define a new condition and select your key figure and define TOP N where N is very high number let say 10000 for sorting them in ascending order and Bottom N for sorting in descending order.
    do revert back if ur prob is solved.

  • How to fill a Key figure at Query run time

    Hi All,
    I have a requirement where I have to fill a key figure while the query is running. This value is obtained by multiplying 2 attributes of a Material Master Data object.I  could have used Formula Variable but there are two problems -
    1. I have material in my info provider but not this Material Master Data object.
    2. For a particular material, there are multiple rows in the Master Data object. And I have to pick only one row by applying some condition on a field of the MD object.
    Please let me know if there is some way to implement this.

    Hello,
    You can obtain this using virtual KF. Create a KF and include in the cube on which report is built. Dont have any mapping/rule for the same.
    Now write ur code using SMOD and populate this KF during runtime.
    Regds,
    Shashank

Maybe you are looking for

  • Looking for a password

    looking for a password for peach willow guest can you help......please

  • Purchase Order back to back with T & C

    Hello All, We use HPOM for priting from SAP. We have printers to print T & C at the back of the PO. Now the T &C have been changed. We have generated a new PS file for the same. Now it is printing the new T&C on a seperate page but not at the back. P

  • Calender freeze while changing to weekly view

    hi my Problem is that I can't change it to the weekly view. always if I try the calender freezes. I've 3 Kalenders an in one is my timetable for university with weekly repeats. thanks for Help

  • Unable to sign into Messages/Face Time

    iPad 4-Unable to sign into Messages/Face Time? Used to work perfectly, now keeps asking for Apple ID but won't accept. Have changed the Apple ID, still a no go. Updates to IOS 8.1.3 and tried all the other restarts etc. no luck.

  • Which box to make app server, and which to make customer db?

    I have 2 boxes: 1) a Sun ultra 10 w/40mb/s scsi, 160mb/s drive, 256mb ram, 366mhz sparc 2) a 1.7 ghz pc clone running linux 7.3, 256mb DDR ram, ATA-100 (but i can only make it run at 25mb/s) both machines have 40mb hard drives. i plan to run portal,