How to Troubleshoot Excel Runtime Error 1004 When Refreshing ODBC Queries
Question details
The user needs to resolve intermittent Excel Runtime Error 1004 (0xC0000374) that appears when Power Query refreshes data through an ODBC driver such as Firebird.

- Product
- Microsoft Excel with Power Query and Firebird ODBC driver
- Device & OS
- not provided
- Scenario
- Refreshing an ODBC query in Excel Power Query.
- Observed behavior
- Intermittent Runtime Error 1004 with code 0xC0000374 appears, which can interrupt the refresh or cause Excel to close.
Before troubleshooting, note the Excel build, Power Query version, and the ODBC driver name, version, and bitness (32-bit or 64-bit). Also identify the approximate number of rows and columns returned by the query so you can test with a smaller refresh.
Check ODBC Driver Bitness and Version Against Excel and Power Query
Use this first when the error is intermittent, appears only on some computers, or started after an Office or driver update.
Runtime Error 1004 with code 0xC0000374 is often caused by a bitness mismatch or an outdated ODBC driver that Power Query calls during refresh.
In Excel, go to File > Account > About Excel and note whether your installation is 32-bit or 64-bit.
Press Windows + S, search for ODBC Data Sources, and open the 32-bit or 64-bit version that matches your Excel build.
Find the Firebird or other ODBC driver, note its version and platform, then install the latest vendor-supported driver with the same bitness as Excel.
Select the data source in ODBC Data Source Administrator, click Configure or Test, and confirm the connection completes without error.
Return to Excel, open Data > Queries & Connections, right-click the query, and choose Refresh after limiting its returned rows.

Reduce the ODBC Query Result Size and Simplify Power Query Steps
Use this when the query still fails after driver compatibility checks, or when the source query returns a large or complex result set.
Collect Power Query Diagnostics and Compare Working and Failing Computers
Use this when the error remains after compatibility and query-size changes, or when the same workbook works on one computer but not another.
Avoid Recurring Excel Runtime Error 1004 Disruptions with WPS Office Spreadsheets
If Microsoft Excel Runtime Error 1004 keeps interrupting ODBC refresh work, WPS Office is a free, lightweight alternative with a familiar ribbon interface and strong Microsoft Excel file compatibility. Use WPS Spreadsheets to open .xlsx workbooks and continue editing without the same Power Query ODBC dependency, while maintaining smooth document migration between Excel and WPS Office.
- 1. Download WPS Office: Click Download WPS Office Free, save the installer, and complete the installation on your Windows computer.
- 2. Open the existing Excel workbook: Launch WPS Spreadsheets and use File > Open to open the .xlsx workbook that previously triggered Runtime Error 1004 in Excel.
- 3. Review and continue editing: Check formulas, formatting, and data ranges in WPS Spreadsheets, and re-create or refresh source data connections as supported by your ODBC driver.

Frequently Asked Questions
Does Runtime Error 1004 during ODBC refresh only happen with Firebird?
No. It can occur with any ODBC driver when there is a 32-bit/64-bit mismatch, an outdated driver, or a query that returns too much data. Test the connection in ODBC Data Source Administrator and refresh a smaller query to isolate the cause.
How do I check whether Excel and my Firebird ODBC driver use the same bitness?
In Excel, go to File > Account > About Excel to see whether Excel is 32-bit or 64-bit. Then open the matching ODBC Data Source Administrator from Windows and inspect the Firebird driver platform. Install the corresponding driver version.
What should I include in a support report for Runtime Error 1004?
Include the exact error code 0xC0000374, the Excel build from File > Account, the Power Query version, the ODBC driver name and version, the query M code or exported query file, and a Power Query diagnostic log from Query Options > Diagnostics.
Can reducing returned columns and rows stop the 0xC0000374 crash?
Often yes, because the crash can relate to memory use or result-set size. Edit the query in Power Query Editor, remove unused columns, add row filters, and disable background preview to test whether the error stops.
Is WPS Office a reliable alternative if Excel keeps crashing during ODBC refresh?
WPS Office can open and save Excel .xlsx workbooks and provides a familiar, lightweight spreadsheet environment. If you do not need Microsoft Power Query-specific ODBC refresh, WPS Spreadsheets can be a practical alternative for editing and data tasks.




