Forum Discussion
Creating X-axis calculated column by combining text column and measure
Hi
I have to use a column which contains User count and Job Role as X-Axis in a Bar chart.
For Example , If my Job role is Architect and User count is 5. I have to create a column value as "Architect -5". Also Job Role and User count both are coming from 2 different tables.
I tried to create calculated column as [ Role] & "( "&([User Count]) &")" . I am getting User count value as 1 for all roles. However I have user count value more than 1 for all the roles.
Could any one please assist me to solve this issue.
- Anonymous1 year ago
Hi yhv ,
I create two tables as you mentioned.
Then I make a relationship between them.
I also create a calculated column.
Combine = VAR UserCountValue = RELATED ( UserCounts[UserCount] ) RETURN JobRoles[JobRole] & " - " & UserCountValueBest Regards
Yilong Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
2 Replies
- shafiz_p
Super User
Hi yhv You are not allowed to use just measure in calculated column. It is against the rule. You need context transition. You need to use calculate function. Wrap you measure with in calculate function. Assuming you have established correct relationship.
Hope this helps!!
If, Please accept it as a solution!!
Best Regards,
Shahariar Hafiz - AnonymousNot applicable
Hi yhv ,
I create two tables as you mentioned.
Then I make a relationship between them.
I also create a calculated column.
Combine = VAR UserCountValue = RELATED ( UserCounts[UserCount] ) RETURN JobRoles[JobRole] & " - " & UserCountValueBest Regards
Yilong Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.