Median Function Unavailable

Published: 16 Sep 2013
Last Modified Date: 06 Jan 2020


When you try to create a calculated field on a live connection, the MEDIAN function is not available.


  • Tableau Desktop
  • Live connection to some data sources
    • Access
    • Amazon Athena
    • Amazon Redshift
    • Cloudera Hadoop
    • HP Vertica
    • IBM DB2 zSeries
    • MySQL
    • SQL Server
    • Teradata
    • IBM Netezza (aka IBM PDA)
    • Legacy Connections to Excel or Text Files
    • SAP HANA


As a workaround, create an extract. For more information, see Extracting Data.

Depending on your scenario, using a Window Median Table Calculation might also resolve the issue. However please note that this table calculation only returns the median of the expression within the window. For more information about this topic, see WINDOW_MEDIAN in the Online Help


When connecting live to a database, then Tableau Desktop queries the database for any functions requested. This allows Tableau Desktop to take advantage of the performance of the database.

Not all databases have a built-in median function, thus Tableau Desktop is not able to send a query with median to these databases.

Additional Information

To voice your support for the inclusion of this feature request in a future product release, add your vote to the following Community Idea: Percentile function on LIVE connection.

You may also consider contacting support for the database in use to enter a feature request for the database itself to include the median function.

Discuss this article... Feedback Forum
Did this article resolve the issue?