User Tools

Site Tools


charting:tableau:functions:count
  • Bookmark "Count" at del.icio.us
  • Bookmark "Count" at Digg
  • Bookmark "Count" at Furl
  • Bookmark "Count" at Reddit
  • Bookmark "Count" at Ask
  • Bookmark "Count" at Google
  • Bookmark "Count" at Netscape
  • Bookmark "Count" at StumbleUpon
  • Bookmark "Count" at Technorati
  • Bookmark "Count" at Live Bookmarks
  • Bookmark "Count" at Yahoo! Myweb
  • Bookmark "Count" at Facebook
  • Bookmark "Count" at Newsvine
  • Bookmark "Count" at Yahoo! Bookmarks
  • Bookmark "Count" at Twitter
  • Bookmark "Count" at myAOL
  • Bookmark "Count" at Slashdot
  • Bookmark "Count" at Mister Wong

Count

The function count is one of the aggregate functions in Tableau, which returns the number of unique values in a field. There are two different types of the count function. The expression count returns the number of items in a group. The expression countd returns the number of distinct items in a group. Null values are not counted. Countd can not be used, if workbooks exist which were created before Tableau Desktop 8.2 that use Microsoft Excel or text file data sources or workbooks that use the legacy connection and workbooks that use Microsoft Access data sources. Before this function can be used, the users have to extract their data into an extract file.1)

Extracts are saved subsets of a data that can be used to improve performance. With extracting the data you also can take advantage of the Tableau functionality that is not available in the underlying data. By defining filters and limits the total amount of data can be reduced. Extracts can improve the performance. For example for file based datasources such as Access or Excel, a full extract takes advantage of the Tableau data engine. For large data sources and if only a subset of data is needed, a filtered extract can limit the load on the server. Extracted data also can be used offline. 2)

The following example shows how to use a count as well as the countd function and shows the differences between both functions. A simple set of data is given in the Microsoft Excel table below.

3)

First of all, the Microsoft Excel data source has to be connected with Tableau. Then you drag the fruit dimension into the marks area.

4)

By clicking on the arrow you can select measures and then click on Count (Dimension).

5) (count function)

6) (countd function)

When using the count function, the grand total is 5, because this function measures the number of fruits which was sold in the different regions. While using the countd function, the grand total is only 3, because it counts the total number of unique items, which is three in this example (apple, banana and orange).

  • Bookmark "Count" at del.icio.us
  • Bookmark "Count" at Digg
  • Bookmark "Count" at Furl
  • Bookmark "Count" at Reddit
  • Bookmark "Count" at Ask
  • Bookmark "Count" at Google
  • Bookmark "Count" at Netscape
  • Bookmark "Count" at StumbleUpon
  • Bookmark "Count" at Technorati
  • Bookmark "Count" at Live Bookmarks
  • Bookmark "Count" at Yahoo! Myweb
  • Bookmark "Count" at Facebook
  • Bookmark "Count" at Newsvine
  • Bookmark "Count" at Yahoo! Bookmarks
  • Bookmark "Count" at Twitter
  • Bookmark "Count" at myAOL
  • Bookmark "Count" at Slashdot
  • Bookmark "Count" at Mister Wong
charting/tableau/functions/count.txt · Last modified: 2016/06/02 23:00 by kalversb