In some cases, you may need to make a more extensive change to the data source used by a Tableau workbook. For example, you might use a local data source in creating your workbook, but need to change to a data source that’s been published to Tableau Server to make it easier to share your analyses and visualizations.
To replace a data source, follow these steps:
1In the Data Connection workspace, choose Data → New Data Source from the main menu.
This conjures the Connect panel.
2In the Connect panel, choose the type of data source you want to use.
Doing so brings up the Open dialog box.
3Using the Open dialog box and navigate to the data source that you want to use.
Click the Open button to continue.
4Click a worksheet tab.
Open a new worksheet.
5Choose Data → Replace Data Source from the main menu.
The Replace Data Source dialog box appears.
6Using the dialog box’s drop-down menus, choose your current and replacement data sources and then click OK.
Your data source is updated.
If the new data source is slightly different from the original, Tableau will still be able to switch to the new connection. Any fields that __have changed in name or data type will provide errors in the Data pane, seen as red exclamation marks.
By right-clicking on the field with the error, an option to replace the field references helps you to update the field from the original data connection with the appropriate field from the new connection. This is true for both replacing and editing the data source.
This is what it looks like if you are switching from one data file to another. The dialog boxes will look slightly different if you are switching to a database on a server, but the concepts are the same.