[英]How do I add a string in a calculated field within Tableau?
Im new to tableau, and trying to create basic viz: 我是Tableau的新手,并尝试创建基本的Viz:
I have created a calculated field that calculated the percent values of a vector within tableau 我创建了一个计算字段,该字段计算了Tableau中向量的百分比值
Repex: Repex:
Cast Total
1 10
2 10
3 10
sum(Cast/10*100) 总和(投放/ 10 * 100)
but this gives me the literal values when I plot it in a tree map. 但这在我将其绘制在树图中时为我提供了文字值。 if I try to do
如果我尝试去做
sum(Cast/10*100)+"%" or + "percent"
I get a syntax error. 我收到语法错误。
Basically within the tree map I want to display it as 1"%" or 2% instead of it just written as 1 and 2. 基本上在树形图中,我想将其显示为1“%”或2%,而不是仅仅写为1和2。
How should I go about this? 我应该怎么做?
将数值表达式包装在STR()
,将其视为字符串:
STR(SUM([Cast]/10*100)) + '%'
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.