4 Replies Latest reply on Apr 25, 2018 6:46 AM by venkatram

    Add Strings to Measure Values

    Gary Bisaga

      I'm having a tough time understanding Measure Values. Attached is a workbook. On the PercentChange worksheet, I have a table. I have this calculated field [Percent Change Direction]:

      In other words, it's a string version of the named field, with an arrow added to the beginning. I want to add this into my Measure Values so it shows up as one of the columns in my table. Unfortunately, when I drag it to the Measure Values shelf:

      Well, that's not what I wanted! I just wanted the value to be displayed in the rightmost column of the table; what I got was it running the CNTD aggregation function. I figure, OK I'll just change the aggregate function used to ATTR:


      What the heck just happened? I don't see anything in the documentation that indicates Measure Values must be numeric! I just want to get this calculated field into my table. This seems like such a simple thing to do. I'm using 10.3.10.

        • 1. Re: Add Strings to Measure Values
          Zhouyi Zhang

          Hi, Gary


          Please find my workaround attached.


          Below is the screenshot of result



          Hope this helps



          • 2. Re: Add Strings to Measure Values
            Gary Bisaga

            Hi Zhouyi, that's brilliant! Unfortunately, I am at a total loss as to what you did to get that result:

            1. I can't see any documentation for multiple marks cards. How do you create them? Is there any relationship between them?

            2. What is AGG(MIN(1))? And since it shows up twice in the "Rows" card, why didn't it create multiple rows?

            3. What does that "Multiple fields" pill represent - what's in it, and how did it get there?

            4. Which column is associated with which Marks card? If I try to modify them, the whole table just falls apart!


            Maybe it would be easiest to just describe (or point me to a description) how you created this. I really have no clue. Sorry for all the questions, I'm desperately trying to understand Tableau. Thank you very much!

            • 3. Re: Add Strings to Measure Values
              Zhouyi Zhang

              Hi, Gary


              This is utilized dummy axis as place holder, as long as there are multiple measures in either columns or rows, you will see the multiple mark cards, and min(1) is the dummy axis and plays as place holder. as in your case, you need one for all the measures and another one for text field, so it appears twice.


              Below is a brief steps and the rest are just formatting


              Have a look at my workbook and try your own, any questions are welcome.



              1 of 1 people found this helpful
              • 4. Re: Add Strings to Measure Values

                Hey Gary,


                Adding to about post @ZHOUYI ZHANG he is tableau guru.


                Zhouyi is create a Dummy variable as Min(1) to place value in IT. Due to some limitations with tableau, your requirement cant achieve directly.

                This a work around for your question. Please check below blog and you will get more clear on why he is created dummy variable in this calculations.


                Different color coding for each column in Tableau Practical blog for Viz Enthusiasts

                1 of 1 people found this helpful