![]() |
VOOZH | about |
One key aspect of working with data in Tableau is managing data types. Tableau automatically detects and assigns data types to fields in a newly uploaded dataset. However, users can modify these data types at multiple stages to suit their analysis.
There are three main ways to change the data type of a field in Tableau:
To modify the data type from the Data Source page:
Example:
We can observe that the data type of the 'User Id' field is 'Number (whole)'. Let's change its data type from Number to String.
๐ ImageAfter this change, the User Id field is updated from Number to String and all associated values reflect the new type.
If we want to change the data type without altering the data source, we can do it from the Data pane:
Example:
We can observe that the data type of field 'Name' is 'String'. Let's change it to Boolean.
๐ ImageAfter applying this change, the Name field is updated from String to Boolean, without modifying the original data source.
You can also modify the data type directly in a worksheet view:
Example:
We can observe that the data type of the 'Location' field is 'String'. Let's change it to Date & Time.
๐ ImageOnce updated, the Location field now reflects the Date & Time type in the view.