1 Reply Latest reply on Feb 27, 2016 3:55 PM by Bill Lyons Branched to a new discussion.

    Adding Non-Existent Values to a Dimension

    Derek Dickinson

      How do I add string values that do not exist in domain? For example, I have field called "stuff", which could contain the following three categories: "foo",  "bar", and "qux". Now, let's assume, depending on the parameters of my query to the data source, one or more of these categories is not present. How do I force Tableau to display these items and populate them with 0?

        • 1. Re: Adding Non-Existent Values to a Dimension
          Bill Lyons

          Depending on your data source, if the values are in a related table, you might be able to use a left or right join.

           

          Depending on the other criteria of your view, you can change the level of the filter according to the filter hierarchy:

          In this way, you retrieve the data from the data source, but do not display all of it in the view.

           

          The last option is to have a data "scaffold," which is a source with all of the category values, that you blend with the data that you want to aggregate against it.

           

          I hope that helps. If you provide a sample packaged workbook (.twbx), I could be more specific in showing examples.