You are currently offline, waiting for your internet to reconnect

FIX: When you use SQL Native Client to retrieve data from a column of the sql_variant data type in SQL Server 2005, an incorrect data type is returned

Extended support for SQL Server 2005 ends on April 12, 2016

If you are still running SQL Server 2005 after April 12, 2016, you will no longer receive security updates and technical support. We recommend upgrading to SQL Server 2014 and Azure SQL Database to achieve breakthrough performance, maintain security and compliance, and optimize your data platform infrastructure. Learn more about the options for upgrading from SQL Server 2005 to a supported version here.

Bug #: 50002687 (SQL Hotfix)
Microsoft distributes Microsoft SQL Server 2005 fixes as one downloadable file. Because the fixes are cumulative, each new release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2005 fix release.
SUMMARY
This article describes the following about this hotfix release:
  • The issues that are fixed by the hotfix package
  • The prerequisites for installing the hotfix package
  • Whether you must restart the computer after you install the hotfix package
  • Whether the hotfix package is replaced by any other hotfix package
  • Whether you must make any registry changes
  • The files that are contained in the hotfix package
SYMPTOMS
Consider the following scenario. An application uses SQL Native Client to connect to an instance of Microsoft SQL Server 2005. In the application, you retrieve data from a column of the sql_variant data type. You call the SQLColAttribute function to determine the data type for the data. In this scenario, an incorrect data type is returned.

Note This problem does not occur if you use the ODBC driver to retrieve data from the column of the sql_variant data type.
RESOLUTION

Hotfix information

A supported hotfix is available from Microsoft. However, this hotfix is intended to correct only the problem that is described in this article. Apply this hotfix only to systems that are experiencing this specific problem. This hotfix might receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next software update that contains this hotfix.

If the hotfix is available for download, there is a "Hotfix download available" section at the top of this Knowledge Base article. If this section does not appear, contact Microsoft Customer Service and Support to obtain the hotfix.

Note If additional issues occur or if any troubleshooting is required, you might have to create a separate service request. The usual support costs will apply to additional support questions and issues that do not qualify for this specific hotfix. For a complete list of Microsoft Customer Service and Support telephone numbers or to create a separate service request, visit the following Microsoft Web site: Note The "Hotfix download available" form displays the languages for which the hotfix is available. If you do not see your language, it is because a hotfix is not available for that language.

Prerequisites

To apply this hotfix, you must have SQL Server 2005 Service Pack 2 (SP2) installed. For more information about how to obtain SQL Server 2005 Service Pack 2, click the following article number to view the article in the Microsoft Knowledge Base:
913089 How to obtain the latest service pack for SQL Server 2005

Restart information

You do not have to restart the computer after you apply this hotfix.

Registry information

You do not have to change the registry.

Hotfix file information

The English version of this hotfix has the file attributes (or later file attributes) that are listed in the following table. The dates and times for these files are listed in Coordinated Universal Time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time item in Control Panel.
SQL Native Client, 32-bit version
File nameFile versionFile sizeDateTimePlatform
Msvcm80.dll8.0.50727.42479,23222-Sep-200515:48x86
Msvcp80.dll8.0.50727.42548,86422-Sep-200515:48x86
Msvcr80.dll8.0.50727.42626,68822-Sep-200515:48x86
Msvcm80.dll8.0.50727.42479,23222-Sep-200515:48x86
Msvcp80.dll8.0.50727.42548,86422-Sep-200515:48x86
Msvcr80.dll8.0.50727.42626,68822-Sep-200515:48x86
Msvcm80.dll8.0.50727.42479,23222-Sep-200515:48x86
Msvcp80.dll8.0.50727.42548,86422-Sep-200515:48x86
Msvcr80.dll8.0.50727.42626,68822-Sep-200515:48x86
Sqlncli.dll2005.90.3257.02,242,58412-Jun-200817:07x86
Sqlnclir.rll2005.90.1399.0205,52813-Oct-200519:48Not applicable
SQL Native Client, x64-based version
File nameFile versionFile sizeDateTimePlatform
Msvcm80.dll8.0.50727.42479,23222-Sep-200515:48x86
Msvcp80.dll8.0.50727.42548,86422-Sep-200515:48x86
Msvcr80.dll8.0.50727.42626,68822-Sep-200515:48x86
Msvcm80.dll8.0.50727.42479,23222-Sep-200515:48x86
Msvcp80.dll8.0.50727.42548,86422-Sep-200515:48x86
Msvcr80.dll8.0.50727.42626,68822-Sep-200515:48x86
Msvcm80.dll8.0.50727.42479,23222-Sep-200515:48x86
Msvcp80.dll8.0.50727.42548,86422-Sep-200515:48x86
Msvcr80.dll8.0.50727.42626,68822-Sep-200515:48x86
Msvcm80.dll8.0.50727.42516,09622-Sep-200515:27x64
Msvcp80.dll8.0.50727.421,097,72822-Sep-200515:28x64
Msvcr80.dll8.0.50727.42822,78422-Sep-200515:26x64
Msvcm80.dll8.0.50727.42516,09622-Sep-200515:27x64
Msvcp80.dll8.0.50727.421,097,72822-Sep-200515:28x64
Msvcr80.dll8.0.50727.42822,78422-Sep-200515:26x64
Sqlncli.dll2005.90.3257.02,763,28812-Jun-200816:18x64
Sqlnclir.rll2005.90.1399.0206,04014-Oct-200506:31Not applicable
Sqlncli.dll2005.90.3257.02,242,58412-Jun-200817:07x86
Sqlnclir.rll2005.90.1399.0205,52813-Oct-200519:48Not applicable
SQL Native Client, Itanium-architecture version
File nameFile versionFile sizeDateTimePlatform
Msvcm80.dll8.0.50727.42479,23222-Sep-200515:48x86
Msvcp80.dll8.0.50727.42548,86422-Sep-200515:48x86
Msvcr80.dll8.0.50727.42626,68822-Sep-200515:48x86
Msvcm80.dll8.0.50727.42479,23222-Sep-200515:48x86
Msvcp80.dll8.0.50727.42548,86422-Sep-200515:48x86
Msvcr80.dll8.0.50727.42626,68822-Sep-200515:48x86
Msvcm80.dll8.0.50727.42479,23222-Sep-200515:48x86
Msvcp80.dll8.0.50727.42548,86422-Sep-200515:48x86
Msvcr80.dll8.0.50727.42626,68822-Sep-200515:48x86
Msvcm80.dll8.0.50727.42572,41622-Sep-200515:29IA-64
Msvcp80.dll8.0.50727.421,385,47222-Sep-200515:31IA-64
Msvcr80.dll8.0.50727.421,484,80022-Sep-200515:28IA-64
Msvcm80.dll8.0.50727.42572,41622-Sep-200515:29IA-64
Msvcp80.dll8.0.50727.421,385,47222-Sep-200515:31IA-64
Msvcr80.dll8.0.50727.421,484,80022-Sep-200515:28IA-64
Sqlncli.dll2005.90.3257.05,443,60812-Jun-200819:47IA-64
Sqlnclir.rll2005.90.1399.0205,01614-Oct-200506:39Not applicable
Sqlncli.dll2005.90.3257.02,242,58412-Jun-200817:07x86
Sqlnclir.rll2005.90.1399.0205,52813-Oct-200519:48Not applicable
STATUS
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.
MORE INFORMATION

Steps to reproduce this problem

  1. In an application, use SQL Native Client to connect to an instance of SQL Server 2005.
  2. Call the SQLColAttribute function to determine the real data type for the data that is returned by the following statement.
    SELECT DATABASEPROPERTYEX(name, 'status') AS [Status] FROM master..sysdatabases
The return type of the DATABASEPROPERTYEX function is sql_variant. The real data type is nvarchar(128). However, when you call the SQLColAttribute function to determine the real data type of the data that is returned by the DATABASEPROPERTYEX function, the function returns SQL_BINARY instead of SQL_CHAR. For more information about the naming schema for SQL Server updates, click the following article number to view the article in the Microsoft Knowledge Base:
822499 New naming schema for Microsoft SQL Server software update packages
For more information about software update terminology, click the following article number to view the article in the Microsoft Knowledge Base:
824684 Description of the standard terminology that is used to describe Microsoft software updates
SNAC
Properties

Article ID: 953946 - Last Review: 06/30/2008 19:47:23 - Revision: 1.0

Microsoft SQL Server 2005 Standard Edition, Microsoft SQL Server 2005 Developer Edition, Microsoft SQL Server 2005 Enterprise Edition, Microsoft SQL Server 2005 Standard X64 Edition, Microsoft SQL Server 2005 Standard Edition for Itanium-based Systems, Microsoft SQL Server 2005 Enterprise X64 Edition, Microsoft SQL Server 2005 Enterprise Edition for Itanium-based Systems, Microsoft SQL Server 2005 Workgroup Edition

  • kbsql2005connect kbautohotfix kbhotfixrollup kbfix kbpubtypekc kbqfe kbexpertiseadvanced kbhotfixserver KB953946
Feedback