
Excel - Refreshing external data (Refresh order)
It is important to note that pivot tables refresh before external data.
If you have a query that imports data from an external source and you have a pivot table based on that data table, then you will need to refresh all twice to get your pivot tables to update, or you can refresh the pivot table manually after by right clicking and selecting refresh.
A way around this is to base your pivot table on the external data source, or create a macro that refreshes your data in the desired order.