Do you need a list of the Tableau Calculations for your clients?
- Dawn Harrington
- Oct 6
- 2 min read
With your development, sometimes your clients want to verify if the calculations you are using are correct for their needs. Wouldn't it be great to get a list of those without manually having to open every single calculated field?
Tableau is xml based. There are many applications you can use to extract that information without wasting hours of your time doing so.
Tableau Ambassador Scott Eaton has used the Rapid Dox application for this purpose but it does have a fee.
I have used an Alteryx macro found in this Alteryx community post here. I have modified it further to extract the data sources / dashboard weblinks and if the calculated fields are pulled again in other calculations. The fields you are looking for in the xml code is "column caption" or "calculation class". If you are looking for the data sources it is "datasources" or "repository-location".
Another method is to pull the information using Tableau's REST API. Link here for more information. You can use GraphQL to pull the information and example is below.
query GetWorkbookCalculatedFields($workbookId: ID!) {
workbook(id: $workbookId) {
sheets {
fields {
name
formula
dataType
isCalculatedField
}
}
}
}
However this can get tricky with having personal access tokens as Tableau DataDev Ambassador Kyle Massey explains in his blog article here.
If you are a Python user there is free python code in this GitHub link created by Ana Milana. She has a webpage here where you can upload your workbook and it will do the analysis for you. I would recommend uploading a workbook with fake data for this process. Simply import the fake data set into your workbook, click on this new data source in a worksheet, and then right-click to select the "Replace Data Source."

Comments