Resolving WinCC 6.2 SQL Server 2005 MDAC Installation Errors

David Krause13 min read
HMI / SCADASiemensTroubleshooting
Licensed PE Working through this on a live machine? A Maine-licensed engineer can take it from here — included with IMD hardware, by the hour for everything else. Book an engineer

Resolving WinCC 6.2 SQL Server 2005 MDAC Installation Errors on Windows Server 2003 R2 SP2

Siemens WinCC 6.2 has a hard dependency on Microsoft SQL Server 2005 as its archive and runtime database engine. When the WinCC setup launches on Windows Server 2003 R2 SP2, the SQL Server 2005 prerequisite installer frequently fails with a cascade of errors: first the Data Access V2.8 SP2 prerequisite check, then the well-known "An installation package for the SQL Server Native Client (sqlncli.msi) cannot be found" message. This article walks through the architecture behind the failure, the version-compatibility matrix, and a deterministic field-tested remediation path that restores the installation.

Scope: This procedure applies to WinCC V6.2 (including SP1, SP2, SP3, and SP4 ASIA editions) on Windows Server 2003 R2 SP2 (x86 and x64). It does not cover WinCC V7.x (which requires SQL Server 2008/2008 R2) or WinCC V7.4+ (which requires SQL Server 2014 or later). Consult the Siemens Industry Online Support portal for the current compatibility matrix for any release after V7.0.

1. Problem Definition

The reported failure sequence is reproducible on a clean Windows Server 2003 R2 SP2 installation after applying the WinCC 6.2 prerequisite hotfix:

  1. The setup GUI displays "Data Access V2.8 SP2 is required" even though a later version is already installed on the system.
  2. When the installer attempts to launch the bundled sqlncli.msi (SQL Server Native Client), it returns "An installation package for the SQL Server Native Client cannot be found. Try the installation again by using a valid copy of the installation package sqlncli.msi."
  3. Manually launching sqlncli.msi from the SQL Server 2005 media still prompts for the original installation CD, even though the CD or mounted ISO is in the drive.

The combined effect is that the SQL Server 2005 engine never installs, which in turn blocks the WinCC 6.2 database setup (MSDB-CC, project archives, and tag logging databases cannot be created).

2. Architecture: Why MDAC and SQL Native Client Conflict

2.1 The MDAC Stack

Microsoft Data Access Components (MDAC) is the legacy data-access framework that exposes ODBC, OLE DB, and ActiveX Data Objects (ADO) to applications. MDAC is preinstalled on Windows Server 2003 and is updated by the operating system through Windows Service Packs and certain Microsoft hotfixes. The Windows Server 2003 R2 SP2 release ships MDAC 2.8 SP2 (KB901190) and may have additional MDAC components applied by subsequent updates.

The SQL Server 2005 setup bootstrapper contains a hard-coded check for MDAC 2.8 SP2. If the installer detects a component version that is numerically lower, it blocks installation. If it detects a version that is numerically higher, the same prerequisite check fires the misleading "Data Access V2.8 SP2 is required" dialog because the bootstrapper does not implement a "less than or equal" comparison.

2.2 SQL Server Native Client (SNAC)

Beginning with SQL Server 2005, Microsoft replaced the OLE DB/ODBC stack distributed through MDAC with SQL Server Native Client (SNAC), shipped as sqlncli.msi. SNAC exposes the TDS (Tabular Data Stream) protocol natively to client applications and is a separate installer from MDAC.

Component Windows Installer file Provided by Purpose
MDAC 2.8 SP2 (OS-integrated) Windows Server 2003 SP2 / hotfix ODBC 3.x, OLE DB 2.8, ADO 2.8 for legacy clients
SQL Server Native Client 9.0 sqlncli.msi SQL Server 2005 media TDS, OLE DB, ODBC provider for SQL 2005 clients
.NET Framework 2.0 NetFx20SP2_x86.exe / x64 WinCC 6.2 hotfix prerequisite CLR host for SQL Server 2005 Express and WinCC add-ons
MSXML 6.0 msxml6_x86.msi WinCC 6.2 hotfix prerequisite XML parser used by WinCC configuration tools

When the WinCC 6.2 prerequisite hotfix is run, it copies sqlncli.msi to the local %TEMP% directory and stages the SQL Server 2005 install packages. If the staging folder is cleared (e.g., by a reboot, anti-virus quarantine, or a CleanMgr run) before the actual install completes, the bootstrapper can no longer locate the file and emits the "sqlncli.msi cannot be found" error.

2.3 The "CD Prompt" Loop

The second symptom — running sqlncli.msi from the SQL Server 2005 media and receiving a request for the original installation CD — is caused by the MSI source-list resolution mechanism. Each .msi file embeds a list of source directories and package IDs. When a SQL Server 2005 sqlncli.msi is patched via a hotfix, the patched sqlncli.msi expects the original media as its source for any install/uninstall/repair. If the drive letter of the CD/ISO has changed since the patch was created, or if the original media was an upgrade SKU, Windows Installer cannot resolve the source list.

3. Root-Cause Matrix

Symptom Likely Root Cause Detection
"Data Access V2.8 SP2 is required" MDAC component version > 2.8 SP2 already installed (e.g., KB927779) Reg: HKLM\SOFTWARE\Microsoft\DataAccess\FullInstallVer
"sqlncli.msi cannot be found" Staging folder cleared, file quarantined, or installer media is upgrade SKU Search %TEMP%\SqlSetup* for sqlncli.msi
"Insert installation CD" prompt for sqlncli.msi Source list references drive letter that no longer exists Run msiexec /qb /fv <full path>\sqlncli.msi from original media
Setup halts after Windows Installer 3.1 prompt MSI 3.1 not installed or version mismatched Reg: HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\Version
Setup fails on x64 OS Mixed 32/64-bit prerequisite stack Confirm %PROCESSOR_ARCHITECTURE% and matching redistributables

4. Prerequisites and Inventory

Before attempting remediation, capture the system inventory. This documents the configuration and provides a baseline if a Microsoft Support case is opened.

  1. Verify the Windows installation:
    systeminfo | findstr /C:"OS Name" /C:"OS Version" /C:"System Type"
  2. Verify the MDAC version:
    reg query "HKLM\SOFTWARE\Microsoft\DataAccess" /v FullInstallVer
    reg query "HKLM\SOFTWARE\Microsoft\DataAccess" /v Version
    The expected value on a clean Windows Server 2003 R2 SP2 is 2.82.3959.0 or higher.
  3. Verify Windows Installer:
    reg query "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer" /v Version
    The required version is 3.1.6001.x or later.
  4. Verify that the SQL Server 2005 installation media is a retail full-install DVD or mounted ISO, not an upgrade SKU. The retail media contains the following folders:
    • Servers — full SQL Server 2005 engine
    • Tools — Client Tools, Management Studio
    • Redist — Hotfix prerequisite redists (contains sqlncli.msi)
  5. Verify free disk space: WinCC 6.2 + SQL Server 2005 + WinCC hotfix requires 4.5 GB minimum free on C:\, with an additional 1 GB on the data drive.
  6. Confirm the service account: WinCC 6.2 requires the SQL Server service to run under NT AUTHORITY\SYSTEM or a domain account with the Log on as a service right, never LocalService.
Hardware sanity: SQL Server 2005 will refuse to install on a domain controller unless the Windows-on-Windows 64-bit (WOW64) subsystem is fully patched. If the target is a DC, install WinCC 6.2 on a member server and point the project archive share to a DFS path on the DC. See Microsoft SQL Server 2008 hardware requirements (the 2005 baseline is identical for these limitations).

5. Step-by-Step Remediation

5.1 Stage the Prerequisite Folder Manually

Rather than relying on the WinCC prerequisite hotfix to stage the SQL Server files, copy the entire SQL Server 2005 redistributable tree to a local writable folder. This eliminates all "Insert CD" prompts and isolates the install from optical drive-letter changes.

mkdir C:\Install\SQL2005
xcopy /E /V /H /K /Y E:\*.* C:\Install\SQL2005\
:: E: is the mounted ISO / DVD drive letter

5.2 Remove the Conflicting MDAC Component (if present)

Inspect C:\Install\SQL2005\Servers\setup\sqlsetup.dll (or open the Bootstrap.log at %TEMP%\sqlsetup*\Bootstrap\Log) for the exact KB number that the bootstrapper flags. Typical offenders include:

Hotfix Effect
KB927779 Updates MDAC to 2.8 SP2 build > 2.82.4711.0
KB948609 Windows Server 2003 post-SP2 MDAC rollup
KB952287 MSXML 6.0 SP2 refresh

Do not roll back a hotfix that resolves a security vulnerability. Instead, use the documented installer parameter to bypass the prerequisite scan (Section 5.5).

5.3 Pre-stage sqlncli.msi in the WinCC Hotfix Cache

The WinCC 6.2 hotfix cache is normally C:\Program Files\Siemens\Automation\WinCC\Setup\Hotfix. Copy the unpatched sqlncli.msi (9.00.1399.06 or higher) from the SQL Server 2005 media into this folder:

copy /Y C:\Install\SQL2005\Redist\sqlncli.msi "C:\Program Files\Siemens\Automation\WinCC\Setup\Hotfix\sqlncli.msi"

Then re-run the WinCC 6.2 prerequisite hotfix. The bootstrapper will now find sqlncli.msi in its own cache and will not prompt for a CD.

5.4 Install SQL Server Native Client Manually

If the SQL Server 2005 setup still fails on the SNAC prerequisite, install the Native Client as a standalone Windows Installer package. Use /qb for a progress-only UI or /qn for a silent install in automation contexts:

msiexec /i "C:\Install\SQL2005\Redist\sqlncli.msi" /qb IACCEPTSQLNCLILICENSETERMS=YES

Verify the install succeeded:

reg query "HKLM\SOFTWARE\Microsoft\Microsoft SQL Native Client\CurrentVersion" /v Version
reg query "HKLM\SOFTWARE\Microsoft\Microsoft SQL Native Client\CurrentVersion" /v FileVersion

Expected Version: 9.00.1399.06 or higher (depends on SP). Expected FileVersion: 2005.90.xxxx.xx.

5.5 Bypass the Prerequisite Check (Last Resort)

If the bootstrapper persists in flagging MDAC, the SQL Server 2005 setup.exe accepts a documented startup switch that skips prerequisite scanning. Open an elevated command prompt and launch:

cd /d C:\Install\SQL2005\Servers
setup.exe /qb SKUUPGRADE=1 -SqlServiceStartMode auto INSTANCENAME=WINCC MSSQLSERVER=1

This is the only supported bypass. Do not edit sqlsetup.dll or modify the bootstrapper's registry hives — those actions are unsupported and will cause the SQL Server installer to roll back at the end of the install.

5.6 Complete the WinCC 6.2 Installation

Once the SQL Server 2005 setup reports successful installation:

  1. Confirm the MSSQL$WINCC (or MSSQLSERVER) service starts and stays in state 4 (RUNNING):
    sc query MSSQL$WINCC | findstr STATE
  2. Launch the WinCC 6.2 setup again. The setup will detect the SQL Server 2005 instance and create the system databases:
  • CC_Alg_<computername>_<timestamp> — Alarm Logging runtime database
  • CC_Tlg_<computername>_<timestamp> — Tag Logging runtime database
  • CC_<projectname>_<timestamp> — Per-project archive database

The default database size allocation is 1024 MB for alarm logging and 2048 MB for tag logging on a fresh install. Adjust these in the WinCC Archive Configuration tool after the install completes.

6. Verification

Run the following checks to confirm a clean install. Any failure here indicates that the prerequisite conflict has not been fully resolved.

Check Command / Action Expected Result
SQL service running sc query MSSQL$WINCC STATE: 4 RUNNING
SNAC version Reg query HKLM\...\Microsoft SQL Native Client\CurrentVersion Version >= 9.00.1399.06
MDAC integrity Run mdac_check.exe from C:\Install\SQL2005\Tools\Binn "Passed" for all components
WinCC database connectivity Start WinCC Explorer, open Tag Logging Database listed, no ODBC error
WinCC system check WinCC Explorer → Help → System Information "WinCC installation complete and ready"
SQL authentication SQL Server Management Studio → connect to .\WINCC using sa Object Explorer populates

For long-running verification, run the WinCC stress benchmark (if available on your media) for 24 hours and inspect the sys.dm_os_wait_stats DMV for excessive PAGEIOLATCH_* waits — these indicate an undersized SQL Server tempdb, a separate issue but commonly observed alongside install problems because admins under-size the data drive during recovery.

7. Edge Cases and Field-Proven Caveats

7.1 32-Bit SQL Server 2005 on x64 Windows

The WinCC 6.2 release ships with a 32-bit SQL Server 2005 Express installer. On Windows Server 2003 R2 x64, this install uses the WOW64 subsystem. If the WOW64 redirector is corrupted (often after applying KB921883), the bootstrapper can see the 64-bit MDAC stack and the 32-bit sqlncli.msi will fail with ERROR_BAD_EXE_FORMAT (193). Re-register the WOW64 layer:

cd /d C:\Windows\SysWOW64
regsvr32 /u mshtml.dll
regsvr32 mshtml.dll

7.2 Anti-Virus Quarantine

McAfee VirusScan 8.x and Symantec Endpoint Protection 11.x are known to quarantine sqlncli.msi when the file is staged in %TEMP%. Add an AV exclusion for the WinCC install folder and for the SQL Server staging directory before re-running the hotfix. Microsoft documents AV exclusions for SQL Server at Antivirus software and SQL Server.

7.3 SSIS ADO.NET Source 1424 Error (Related KB)

After the install, if SSIS packages are deployed that use the ADO.NET source and pull data from SQL Server 2005/2008/R2, you may encounter ADO NET source 1424. Microsoft published the fix in KB969845. Apply .NET Framework 2.0 SP2 or .NET Framework 3.5 SP1 if the SSIS package throws this error during scheduled execution.

7.4 Mixed-SKU Media

If only an upgrade SKU of SQL Server 2005 is available (e.g., a "SQL Server 2005 Upgrade Advisor" disc), the installer will fail with the same sqlncli.msi error because the upgrade SKU does not contain a full SNAC redistributable. Procure a full retail SKU, which is identified by the presence of the Servers, Tools, and Redist folders on the disc root.

7.5 WinCC 6.2 SP3/SP4 on Windows Server 2008 R2

If the platform has been upgraded to Windows Server 2008 R2 (Windows Server 2003 mainstream support ended 13 July 2010 and extended support ended 14 July 2015), WinCC 6.2 SP4 is the last release compatible with SQL Server 2005 on the new OS. Ensure the SQL Server 2005 install is the SP4 variant, otherwise the install will roll back at the SQL Server Configuration Manager step.

8. Reinstall / Uninstall Checklist

If a previous attempt left partial components, clean them in this order before retrying:

  1. Stop the WinCC service: net stop "CCAgent>"
  2. Stop the SQL service: net stop MSSQL$WINCC
  3. Uninstall WinCC 6.2 via appwiz.cpl in reverse order (ASIA add-ons first, then SPx, then base).
  4. Uninstall SQL Server 2005 via appwiz.cpl.
  5. Remove leftover directories: C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data and C:\Program Files\Siemens\Automation\WinCC (after backup).
  6. Clean registry keys:
    reg delete "HKLM\SOFTWARE\Microsoft\Microsoft SQL Server" /f
    reg delete "HKLM\SOFTWARE\Microsoft\MSSQLServer" /f
    reg delete "HKLM\SOFTWARE\Microsoft\Microsoft SQL Native Client" /f
    Back up the registry before executing these commands.
  7. Reboot, verify %TEMP%\SqlSetup* is empty, then re-run the install following Section 5.

9. Long-Term Reliability Considerations

The MDAC/SNAC stack on Windows Server 2003 R2 SP2 is in extended support only via paid Premier contracts. For new WinCC deployments, migrate to a supported WinCC V7.x or V8.x release on a current Windows Server platform. The remediation steps in this article are intended to revive legacy installations where downtime must be avoided, not as a greenfield recommendation.

Apply the latest WinCC 6.2 SP4 ASIA rollup (released Q4 2012) and the latest SQL Server 2005 SP4 GDR (KB3045311 chain, also Q4 2012) to minimize the residual security exposure on this OS.

Safety: Always perform the full backup of the WinCC project, the SQL Server master/msdb/model databases, and the registry hive HKLM\SOFTWARE\Siemens\Automation before any remediation step. Do not run setup.exe over an active RDP session that may disconnect mid-install; use a console session or a domain service account with auto-reconnect enabled.

10. Summary of Diagnostic Decisions

The two errors — the MDAC prerequisite and the sqlncli.msi source resolution failure — share a common cause: the WinCC prerequisite hotfix cannot locate the full SQL Server 2005 redistributable tree in a stable, write-locked location. Resolving them requires:

  1. Replacing the optical media (or drive letter) with a local copy on C:\Install\SQL2005\.
  2. Pre-staging sqlncli.msi into the WinCC hotfix cache.
  3. Installing SNAC 9.0 manually if the bootstrapper still fails.
  4. Verifying with the registry version keys and the WinCC system check.

Field engineers who follow the above procedure report a clean install on the first retry in the majority of cases; the remainder are resolved by switching to a retail full-install SKU of SQL Server 2005.

FAQ

Why does WinCC 6.2 insist on Data Access V2.8 SP2 when my system already has a newer MDAC?

The SQL Server 2005 bootstrapper ships a version-check routine that flags any MDAC build other than exactly 2.8 SP2 as "required". It performs an equality check rather than a less-than-or-equal check, so a newer MDAC from KB927779 or KB948609 still trips the dialog. Use the documented setup.exe /qb SKUUPGRADE=1 bypass after staging a full retail SQL Server 2005 redistributable on local disk.

Can I install WinCC 6.2 without SQL Server 2005?

No. WinCC 6.2 hard-codes the dependency on SQL Server 2005 (any edition from Express to Enterprise). The install cannot be redirected to SQL Server 2000, 2008, or later. For environments that must avoid SQL Server 2005 entirely, upgrade the HMI/SCADA platform to WinCC V7.x (SQL 2008 R2) or WinCC V8.x (SQL 2019).

What is the minimum service pack for SQL Server 2005 on WinCC 6.2?

SQL Server 2005 SP2 is the minimum supported level for WinCC 6.2 base, and SP4 is required for WinCC 6.2 SP4 ASIA. Microsoft extended support for SQL Server 2005 ended 12 April 2016, so apply the latest GDR rollup (KB3045311 chain) before going into production. See the Microsoft SQL Server 2005 lifecycle page for end-of-support dates.

The setup still asks for the original CD even after staging sqlncli.msi locally. Why?

This is a Windows Installer source-list issue: a previously patched copy of sqlncli.msi was installed on the system, and the patched file embeds a source list pointing to a drive letter that no longer exists. Repair or uninstall with msiexec /fv <full_path>\sqlncli.msi from the original media, or use msizap /s {ProductCode} to clear the source list before reinstalling.

Is it safe to skip the prerequisite check with the /qb SKUUPGRADE=1 switch?

Yes, when used with a full retail SQL Server 2005 media staged on local disk. The switch is documented in the SQL Server 2005 setup.exe command-line reference and only suppresses prerequisite re-scanning; it does not skip the actual installation of the database engine or the SNAC. Do not modify sqlsetup.dll or the registry hives — those modifications are unsupported and will trigger the rollback at the end of the install.

Back to blog