What is an Attribute in Tableau? 2 simple examples

Nouer Uz Zaman
2 min readAug 10, 2022

When I first started working with Tableau I frequently use to come across the word Attribute but I did not really know what it meant. If you want to know please read on.

First the definition

In plain English attribute means “quality or feature regarded as a characteristic or inherent part of someone or something”. In plain technical language attribute means the following:

Is the value/result same for every row in a table. If yes return a value and if not then return *(asterisk).

This definition is the simplified version of the official definition; as shown in the image below.

So, if we look at the example below. You will notice that I had written ATTR next to Policy Number field and in return you will see asterisk sign next to some Group Name fields. This means that there are multiple Policy Numbers for that specific group. However for groups like Group 19 there is only one unique Policy Number.

When it comes handy

Aggregate Functions come really handy when working with aggregate and non-aggregate comparisons.

So, say we want to see if there is any null values in group name field and if there is no null then simply return the price change. However, when you run the code it does not work because 1st statement is non-aggregate and 2nd statement is aggregate. In other words both statements are working simultaneously in a sense that 2nd statement is trying to add something up however 1st statement is trying to compare something which is not added up. In the “If” statement both have to aggregate for it to work.

Then by simply putting ATTR before Group Name field solves the problem.

--

--