7 Replies Latest reply on Apr 27, 2017 1:07 PM by chakradhar kakani

    Show or Hide Date filter based on another filter condition

    chakradhar kakani

      Hello Tableau Users,

       

      I'm going through a tricky scenario, can somebody please help me.. Attached a workbook, i have a view where No filter value in PRODUCT filter is selected and the view is blank because nothing is selected in PRODUCT filter dropdown.. I want the Date filter dates to show even though no Product Filter value is selected so that I can narrow the PRODUCTS based on selection of date (this can only be achieved by having date filter not being cascaded only product filter cascaded).. i also want the vice versa where if the PRODUCTS are selected and show the relevant DATES..

       

      i was looking for a idea of hiding and showing of sheets.. where show the Date filter sheet (without Cascaded one) when NONE Products are selected so that they can narrow the Product filter list and vice versa when a users makes a selection in PRODUCT filter, pop in another sheet which has a DATE filter which is cascaded and disappear the sheet without cascaded date filter sheet when a user select any value in Product filter.

       

      Appreciate the help

       

      Thanks

        • 1. Re: Show or Hide Date filter based on another filter condition
          Matthew Risley

          ". I want the Date filter dates to show even though no Product Filter value is selected"

           

          What exactly do you mean by this? That you'd like the Date headers to show even though the view is blank?

           

          Best,

          --Matt

          • 2. Re: Show or Hide Date filter based on another filter condition
            Joe Oppelt

            You can pop objects in and out of your dashboard if you can create a detectable condition and then display (or not) a sheet upon that condition.

             

            In the attached I did the following:

             

            1)  I created a calc called [How many products?].  It's a FIXED LOD that does a countd of the products.

             

            2)  I did EXTRACT on the data source so that COUNTD works.  (Requires an extracted data source.)

             

            3)  I created a sheet:  "Pop out when product selected"

             

            4)  I moved the [Product] filter into context so that the FIXED calc is governed by the filter.

             

            5)  I applied the [Product] filter to both Sheet 1 and the new sheet I made.

             

            Go to that new sheet.  De-select all products.  You'll see that the row goes away.  Select one (or more) and the row comes back.  This is the mechanism I will use to push something into view.

             

            Go to Dashboard 1.  Sheet 1 has been added to the dashboard.

             

            Go to Dashboard 2.  I made a floating horizontal container, and I dragged the pop-out sheet into it.  I did "Hide Title" for the sheet.  I also dragged a text box into it.  (This is what is getting pushed for my example.)  Select and de-select product.  You will see how the text box gets pushed back and forth based on the condition.

             

            Go to Dashboard 3.  I moved the horizontal container so that it starts at a negative x-axis starting position.  Select and deselect a product.  Now when the pop-out sheet collapses, the text box moves into negative space, and you don't see it.  Select a product and the pop-out sheet expands and pushes the text box into view.


            This is called "popping".

             

            I used a FIXED LOD to detect the positive and negative condition, but there are lots of ways to control when the pop-out sheet displays or not.

             

            You can pop your filters into (and out of) view using this same technique. Now, I'm not sure what conditions you want things to be visible, but this is the technique you can use to control that.


            See attached.

            • 3. Re: Show or Hide Date filter based on another filter condition
              Joe Oppelt

              A point of design here.

               

              You have selected "only relevant values" for your date filter.  When you have no products selected, your date filter goes blank.  Your user can see the filter title, but he won't be able to select any dates under this condition.  You should have that set to all values in the database so he has a functional filter when no products are selected.  But even if he selects a date, nothing will show up in your sheet because no products are selected yet.

              • 4. Re: Show or Hide Date filter based on another filter condition
                chakradhar kakani

                Matthew Risley Thanks for the Reply..Yess the header to show when no value is selected

                • 5. Re: Show or Hide Date filter based on another filter condition
                  chakradhar kakani

                  Hello Joe Oppelt thanks for the workaround.. but the whole point  was to show the sheet with the date filter with one set to all values in the database no product is selected .. and show the sheet with date filter which is set to only Relevant Values when atleast one Product is selected.

                   

                  I have attached another workbook, in dashboard 2 is taken a copy of Date filter and applied it to the "Sheet 1 and Pop out when Product selected Sheet".. when i dont select a Product Filter I see COPY of the Date which is fine and now comes the tricky part where if i select atleast one Product the filter which is set to All values in the database should disappear and relevant Values ones should come into play.

                   

                  appreciate your help once again

                  • 6. Re: Show or Hide Date filter based on another filter condition
                    Joe Oppelt

                    chakradhar kakani wrote:

                     

                    Hello Joe Oppelt thanks for the workaround.. but the whole point  was to show the sheet with the date filter with one set to all values in the database no product is selected .. and show the sheet with date filter which is set to only Relevant Values when atleast one Product is selected.

                     

                     

                    The filter is going to do what the selections tell it to do.  If no products are selected, you're not going to get ALL products on the sheet.

                     

                    We can still do some things to recognize if the user has selected ALL or something less than ALL.  But you are not going to override a "none" selection with ALL behind the scenes.

                     

                    Well, that's not entirely true, actually.  We can swap sheets so that if NONE are selected, another sheet with ALL will take the place of the first sheet.

                     

                    What you are describing is going to be complicated, and a maintenance headache.  And I can foresee that I'm going to end up spending a bunch of hours working through this with you, and I don't have time for that.  (This forum isn't my real job, after all...)  Are you sure this requirement is necessary?

                    • 7. Re: Show or Hide Date filter based on another filter condition
                      chakradhar kakani

                      Joe Oppelt Thanks for the Help Joe.. yes its one of my Business ask.. its okay if you cant work on it,, i'll try to work on my own or will wait somebody will help me out,