4 Replies Latest reply: Feb 18, 2016 1:32 PM by Sunny Talwar RSS

    chart should change with filters

    naveen kumar

      Hello guys

      well what i am thinking in that i feel i should had get output what i am expecteing but its not happening .

      suppose i have got the table like this

      table1:                                                                                      table2:

      places      amount    category                                                      location                    places

      dadar          200            smelting                                                    mumbai                  dadar

      dadar          100            mining                                                      mumbai                 malad

      malad          100          smelting                                                    mumbai                goregoan

      malad            50          mining                                                        rajasthan              udaipur

      goregoan        150        smelting                                                      rajasthan              jaipur

      uadipur          100          smelting                                                                           

      jaipur              150        mining .......

      NOTE:category(smelting ,mining) two different bar charts

      BY default i am showing all the smelting in one chart and mining in one chart irrespective of the selection..which looks like this

      table:

      category            amount

      smelting              550(sum(dadar+malad+goregoan+uadipur)

      mining                  300(sum(dadar+malad+jaipure)


      what client requirement is i need to show to filters 1.location

                                                                                2.place

      if he select only  location(mumbai)    from the drop down without choosing place filter then

      TABLE:

      category                      AMOUNT

      smelting                        450(sum(dadar+malad+goregoan))

      mining                          150   

       

      and if he go farther and select place also from the drop down then  in the same bar chart it should like this

      suppose if he select (location :mumbai, place:dadar)

       

      the chart should show this:

      category                  amount

      smelting                    200

       

      my expression what i writen is this:

      sum({<category={'smelting'},location={"*"},place={"*"}>}amount)....

      sum({<category={'mining'},location={"*"},place={"*"}>}amount)....

       

      but its not working in this way any suggestions please

       

       

      thanks

      naveen