Table of Contents


Recently saw an issue when someone created Excel with External Data source to pull data into the worksheet.  By default, we get the option to ‘Refresh data when opening the file’. Excel file is then saved to a SharePoint site collection. Now when users try to open the file in Online Excel it shows warning as 'Be careful, This workbook contains one or more queries that might be unsafe. Do you want to enable these queries?'.

If yes is chosen it then shows error 'External Data Refresh Failed: We are unable to refresh one or more data connections in this workbook. The following connections failed to refresh'.


The SharePoint site is trying to access external data which may be not non to end user.  The end user gets this warning message due to security.

Resolution for SharePoint On-Premises:

1. Go to SharePoint Central Administration > Application Management

2. Service Applications > Manage service applications > Excel Services application > Trusted File Locations and click on the Address that contains the workbook



3. In the External Data section, under Warn on Refresh, uncheck Refresh warning enabled and click OK.



4. Users who access the workbook will no longer be presented with a warning dialog box.

For SharePoint Online or Office 365:

Because the option needs the SharePoint Central Admin level permission that is not opened to the public in Office 365 now. The feature to disable the ‘Data Refresh Warning’ is not available yet in SharePoint Online panel.

For PowerBI, there is an button to control the Refresh schedule to OFF. See the article below: