forums
Use these forums to ask questions and discuss Tableau.
Assigning values to alliases
I need to be able to assign aliases to several values of a dimension at once. The list is similar to the long list below.
How do I assign the aliases without having entering them in one at a time? In statistical packages these are "value labels' or 'value formats', but so far I do not see such a capacity in Tableau.
Does any one have a way to assign a lot of alliases in a hurry?
thanks -
0 ='No Transfer'
1 ='Swedish'
10 ='Virginia Mason'
102 ='Yakima Regnl'
104 ='Valley (Monroe)'
106 ='Cascade Valley (Arlington)'
107 ='N Valley (Tonasket)'
108 ='Tri-State MH'
111 ='Adams Rural'
125 ='Othello'
126 ='Highline'
128 ='Univ WA'
129 ='Quincy Valley'
130 ='Northwest'
131 ='Overlake'
132 ='St Clare'
137 ='Lincoln'
138 ='Stevens'
139 ='Holy Family'
14 ='Childrens (Seattle)'
140 ='Kittitas Valley'
141 ='Dayton GH'
142 ='Harrison MH'
145 ='St Joseph (Bellingham)'
146 ='Allenmore'
147 ='Mid-Valley (Omak)'
148 ='Fifth Avenue'
150 ='Coulee'
152 ='Mason GH'
153 ='Whitman'
155 ='Valley (Renton)'
156 ='Whidbey GH'
158 ='Cascade'
159 ='Provd St Peter'
161 ='Kadlec'
162 ='Sacred Heart'
163 ='Island'
164 ='Evergreen'
165 ='Lake Chelan'
167 ='Ferry Cnty MH'
168 ='Central WA'
169 ='GHC Eastside'
170 ='Washington'
172 ='Pullman MH'
173 ='Morton GH'
175 ='Mary Bridge Childrens'
176 ='Tacoma GH'
180 ='Valley (Spokane)'
183 ='Auburn Regnl'
186 ='Mark Reed'
191 ='Provd Centralia'
194 ='St Joseph H (Chewelah)'
197 ='Capital'
198 ='Sunnyside'
199 ='Toppenish'
20 ='GHC Central'
200 ='Hospice Care Center'
201 ='St Francis'
21 ='Newport'
22 ='Lourdes'
23 ='Okanogan-Douglas Cnty'
26 ='St Johns (Longview)'
27 ='Provd Everett'
29 ='Harborview'
3 ='Provd (Seattle)'
30 ='Mount Carmel'
32 ='St Joseph (Tacoma)'
35 ='Enumclaw'
37 ='Deaconess'
38 ='Olympic'
39 ='Kennewick GH'
42 ='Deer Park'
43 ='Shriners Children'
44 ='Walla Walla GH'
45 ='Columbia Basin'
46 ='Prosser MH'
50 ='St Mary'
506 ='W State'
507 ='E State'
54 ='Forks'
56 ='Willapa Harbor'
58 ='Yakima Valley'
63 ='Grays Harbor'
701 ='Naval Air Stat'
704 ='Naval Regnl'
705 ='VA H (Tacoma)'
707 ='Fairchild AF Base'
710 ='VA(Seattle)'
715 ='VA(Spokane)'
720 ='Madigan Army'
73 ='Skagit Valley'
78 ='Samaritan'
79 ='Ocean Beach'
8 ='Klickitat Valley'
80 ='Odessa MH'
81 ='Good Samaritan'
82 ='Garfield Cnty'
83 ='Puget Sound'
85 ='Jefferson GH'
Comments
Hello friend,
The development team is definitely aware of this annoyance, and I've added your feedback for future decisions.
In the meantime, here's an "undocumented Tableau" workaround. I used a regular expression to reprocess your aliases into a form that looks like this: "<alias key='0' value='No Transfer' />", and attached that file to this post.
Open your workbook, make a single alias for that dimension (I'll call it "Transfers"), save the workbook, and exit. If you then open up your .twb file in a text editor, you'll be able to find a line with "name='[Transfers]'" in it, followed by a line that contains "<aliases>". In between the "<aliases>" and "</aliases>" lines for that dimension, you want to paste the contents of the file I've attached (replacing the single alias with all of them).
Save the file, reopen it in Tableau, and all your aliases should be there. Hopefully that should get you through until Tableau provides something nicer for bulk alias editing. :)
If you prefer, you can maintain the aliases in your database instead of the twb file.
If you can add a table to your database (or worksheet to your Excel spreadsheet), then you can add a table containing your aliases, and then left join to it via the data connection panel. The effect would be to add another (equivalent) field to your schema, say Transfer_Alias, that was more readable.
1. Create table Transfer_Alias_List with columns Transfer_Value and Transfer_Alias
2. Modify your data connection to see multiple tables, include the new Transfer_Alias_List table, left join on the Transfer_Value column. (Use a left join unless you are certain that your alias list is complete for all time)
3. Use the new Transfer_Alias field instead of the Transfer field whenever you want to display the alias.
4. If Transfer_Alias is ever null, it means that a new transfer code came along -- so you need to update the Transfer_Alias_List table to provide an alias for it.
James,
This worked like a charm!! Thank you very, very much.
For sure, this feature needs to be added in the main stream, but in the meantime your workaround completely solves the problem.
I was amazed it worked - first try in under a minute, and I was amazed that I did not somehow corrupt the file in the process. I fixed several others the same way in a few minutes.
Seems it would be possible to write a SAS program to add these aliases very quickly to the tableau file. In my data the variables frequently have a long alias list.
I have resorted to putting the variables in the original data as strings, but that is space consuming and slows things down. Also if I want to make a change, I have to go back to theoriginal data. Best to do it in the Tabeau workbook.
Again, thank you ...
By the way, I almost did not buy Tableau when I discovered this problem when I was using the trial software. I figured there had to be some way that this could be solved, at least by the back door.