0

In tableau i'm trying to create a KPI based on the "Number of disciplines entered by continents", so i'll have for example a pie chart of continents with a figure in each saying how many disciplines have entered.

I am inputting this in my KPI as "WHERE [Name] CONTAINS([Discipline])" which i'm hoping to display all disciplines in a country but i'm getting an error as shown in the screenshot.

error Data

AaronW2
  • 29
  • 5
  • That looks like a partial SQL statement, not a Tableau formula. It is also very unclear what you want to achieve. If you simply created a Tableau table by dragging the country pill into Rows and then dragging Discipline into rows as well, you should immediately get what you want. – matt_black Apr 22 '22 at 12:35
  • @matt_black I understand that but I need to create a KPI which can just be done through calculated field? Also I want to achieve a result where when hovering or clicking on "Name" for countries, it should show the disciplines entered in each country. – AaronW2 Apr 22 '22 at 15:26
  • If you just want to count the disciplines per country, then create a calculation like `countd([Discipline])` and this will give the KPI that you can use in any table of viz where Country is listed. – matt_black Apr 22 '22 at 15:29

0 Answers0