How to fix Error 7367 on Windows Server 2025 / Windows 11

Troubleshooting Guide: SQL Server Error 7367 – OLE DB Provider Column Level Collation Issue

Why This Error Happens

This error occurs when the OLE DB provider used by a linked server supports column-level collation, but SQL Server 2025 is unable to properly retrieve or map the collation metadata for one or more columns in the remote data source. This typically happens due to outdated or misconfigured OLE DB provider drivers, incompatible collation settings between the local SQL Server instance and the linked server, or corrupted provider registration in Windows Server 2025. In some cases, this also surfaces when querying heterogeneous data sources (like Excel, Access, or older SQL Server versions) where collation metadata cannot be fully translated.

Step-by-Step Resolution Guide

Step 1: Verify and Update the OLE DB Provider

  • Open SQL Server Management Studio (SSMS) and navigate to Server Objects > Linked Servers > Providers.
  • Right-click the provider in question (e.g., MSDASQL, SQLNCLI, or MSOLEDBSQL) and check its version under Properties.
  • Download and install the latest version of the Microsoft OLE DB Driver for SQL Server from the official Microsoft Download Center.
  • Restart the SQL Server service after installation: Restart-Service MSSQLSERVER (PowerShell, run as Administrator).

Step 2: Adjust Provider Options for Collation Handling

  • In SSMS, right-click the specific Linked Server and select Properties.
  • Under the Provider Options tab, enable the following checkboxes if disabled:
  • Nested Queries
  • Level Zero Only (uncheck if currently checked)
  • Allow InProcess
  • Click OK and test the connection by right-clicking the linked server and selecting Test Connection.

Step 3: Modify the Query to Use Explicit Collation

  • Update the T-SQL query to explicitly cast the collation on the affected column(s):
SELECT ColumnName COLLATE SQL_Latin1_General_CP1_CI_AS
FROM OPENQUERY(LinkedServerName, 'SELECT ColumnName FROM RemoteTable')
  • Ensure this collation matches the collation of your local SQL Server instance (SELECT SERVERPROPERTY('Collation')).

Step 4: Rebuild the Linked Server Configuration

  • Drop the existing linked server:
EXEC sp_dropserver 'LinkedServerName', 'droplogins';
  • Recreate it with explicit collation compatibility settings:
EXEC sp_addlinkedserver 
    @server = 'LinkedServerName', 
    @srvproduct = '', 
    @provider = 'MSOLEDBSQL', 
    @datasrc = 'RemoteServerIP';
EXEC sp_serveroption 'LinkedServerName', 'collation compatible', 'true';

Step 5: Check Windows Registry for Provider Corruption

  • Open regedit on Windows Server 2025 and navigate to:
    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSSQLServer\Providers
  • Confirm the AllowInProcess and DynamicParameters DWORD values are set to 1 for the relevant provider key.
  • If values are missing or corrupted, uninstall and reinstall the OLE DB provider package entirely.

Alternative or Verification Steps

  • Run a test query using OPENQUERY against the linked server to confirm data returns without the 7367 error; check the SQL Server Error Log via EXEC sp_readerrorlog to confirm no recurrence.
  • If the error persists, consider switching the linked server provider from MSDASQL to the native MSOLEDBSQL driver, as it offers more robust handling of column-level collation metadata in SQL Server 2025.