7 Replies Latest reply on Oct 27, 2016 7:22 PM by Felicha Wolf

    Vertical List of Attributes

    Felicha Wolf

      I need to create vertical list of attributes (e.g. age, weight, car, favorite sport) for a group of individuals.

       

      I don't want them displayed horizontally like in a regular cross tab, but rather vertically as in the dashboard in the attached packaged workbook.

       

      Unfortunately the only way I've been able to do it is to create separate worksheets for each attribute - very wasteful of system resources and kludgy.

       

      Please take a look at the dashboard in the attached, and select the names, and see how the items below, listed vertically, change based on each selection.

       

      What's a better way to do this?

       

      Thanks

        • 1. Re: Vertical List of Attributes
          Sherzodbek Ibragimov

          Felicia

          Have you tried to achieve it by pivoting those vertical dimensions as you want as the one column, see for example:

           

          • 2. Re: Vertical List of Attributes
            Sherzodbek Ibragimov

            i couldn't see your data source thus i can't try it for you. else, please attached excel file as well. Thanks

            • 3. Re: Vertical List of Attributes
              Sherzodbek Ibragimov

              First pivot:

               

               

              Now once you select names, it will show only relevant info pertaining to that person. i have done for some part of your information only. So for full list, you should pivot all related dimension that you would like to use, but name. Attached a workbook for more info.

               

              Thanks

              Sherzod

              • 4. Re: Vertical List of Attributes
                Felicha Wolf

                Thanks very much - attached is my spreadsheet.  I thought I had saved the data as an extract with the .twbx.  Apologies if this was not the case and I have attached that again just to be sure.

                 

                I like your idea of pivoting the data, unfortunately my data set as a lot of other data in it and pivoting would adversely impact the other dependencies I have on it.

                 

                If I can't find a way to do this programmatically within Tableau I may need to go that route however.

                • 5. Re: Vertical List of Attributes
                  Mahfooj Khan

                  Hi Felicha,

                   

                  As you've mentioned data formatting can not be changed. So, I've came up with a solution which might help you to achieve your goal. You can use "Custom SQL" to transform (pivot) your data like this. Can you tell me which data source are you using? If you're using spreadsheets then you've to connect your file with legacy connection.

                   

                  Custom SQL query would be like this

                   

                  SELECT [Name],'Age' AS Attribute,[Age] AS Attribute_Value FROM [Sheet1$] UNION

                  SELECT [Name],'Car',[Car] FROM [Sheet1$] UNION

                  SELECT [Name],'Eye Color',[Eye Color] FROM [Sheet1$] UNION

                  SELECT [Name],'Favorite Food',[Favorite Food] FROM [Sheet1$] UNION

                  SELECT [Name],'Hair Color',[Hair Color] FROM [Sheet1$] UNION

                  SELECT [Name],'Hobby',[Hobby] FROM [Sheet1$] UNION

                  SELECT [Name],'Home Town',[Home Town] FROM [Sheet1$] UNION

                  SELECT [Name],'Pet',[Pet] FROM [Sheet1$] UNION

                  SELECT [Name],'Sport',[Sport] FROM [Sheet1$] UNION

                  SELECT [Name],'Weight',[Weight] FROM [Sheet1$]

                  After custom sql your data view would be like this.

                  then just drag your Attributes and Attribute Values and put filter on Name like this.

                  Hope this help. Let me know If you've any query. Workbook (version 9.3) attached for your reference.

                   

                  Mahfooj

                  1 of 1 people found this helpful
                  • 6. Re: Vertical List of Attributes
                    Sherzodbek Ibragimov

                    Felicha,

                    You are right, if you made some calculation on each attributes and attribute values, then it will mess up your calculation that were based on original structure. Even if does, still you may find it very useful down the road to use pivoted structure when you handle various cases where you need to use pivoted structure to achieve your results. If you do either pivoted way or Custom SQL way.

                    1 of 1 people found this helpful