6 Replies Latest reply: Oct 13, 2011 4:41 AM by Dennis Hoogenboom RSS

    custom bar sort in chart

      Hi,

       

      I've made a waterfall chart as shown in the picture. In this example A,B,C....etc. is a portfolion of brands. I woul like to sort the bars in different order. For instance A,B,C,H,E,I,G,F,D,L,K,J. I am new in qlikview and don't have any idea the solution of that.

       

      Thank you for your assistance!

        • custom bar sort in chart
          Dennis Hoogenboom

          Did you check the option in the "Sort" tab?

          Here you can pick any "Sort by" you want.

          Is there a logic behind your order or is it random?

          • custom bar sort in chart

            There is no logic behind the sort order. A,B,C...... are calculated dimensions. In the picture I've changed their names due to trade secret.From the other hand I can't sort them by name because VS bar nad LY bar will change their possitioin and the meaning of the waterfall chart will be lost. My idea is to make some sort of  Expression maybe but i don't know how to do it

              • custom bar sort in chart
                Sunil Chauhan

                go to sort -> select Y axis ascending /descending  as per need .

                • custom bar sort in chart
                  Dennis Hoogenboom

                  Let me see if I understand you correctly:

                   

                  You say A,B,C are calculated dimensions, then you should be able to rearange the order of your dimensions right? (Promote/Demote on your Dimensions tab)

                   

                  You also say you created a waterfall chart. Normaly I make a waterfall chart by using Expressions with the Bar Offset option, and without a Dimension. If that is the case you can reanrange the order of your Expressions (Promote/Demote on your Expression tab)

                • custom bar sort in chart
                  Kamal Naithani

                  Hi icehorde ......go to the Properties and after that go to the sort tab and make the sorting as per your reqirement.

                  • Re: custom bar sort in chart
                    Dennis Hoogenboom

                    If you want to sort your outcome in an order that has no logic, but is always the same order, you could add something like an SortID to your original data. Take a look at the QV-file I attached. something like:

                     

                     

                    // Your data


                    Data:    

                    LOAD Account,

                         Data

                    FROM

                    data.xls

                    (biff, embedded labels, table is Sheet2$);

                     

                     

                    // Join the SortID to Account

                    Join (Data)

                    LOAD * INLINE [

                        Account, SortID

                        A, 4

                        B, 3

                        C, 1

                        D, 5

                        E, 7

                        F, 6

                        G, 2

                    ];

                     

                     

                    Then use SortID in your sort Expression

                     

                    Knipsel.JPG

                     

                     

                    Let me know if it is what your looking for or not.

                     

                     

                    Good Luck,

                    Dennis.