Microsoft KB Archive/926335

= FIX: Error message when you trace the Audit Database Management event and you try to bring a database online in SQL Server 2005: “Msg 942, Level 14, State 4, Line 1” =

Article ID: 926335

Article Last Modified on 11/20/2007

-

APPLIES TO


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

-



Bug#: 481813 (SQLBUDT )



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 this hotfix package
 * The prerequisites for applying the hotfix package
 * Whether you must restart the computer after you apply the hotfix package
 * Whether the hotfix package is replaced by any other hotfix package
 * Whether you must make any registry changes after you apply the hotfix package
 * The files that are contained in the hotfix package



SYMPTOMS
In Microsoft SQL Server 2005, you may receive the following error message:

Msg 942, Level 14, State 4, Line 1

Database  cannot be opened because it is offline.

Msg 5069, Level 16, State 1, Line 1

ALTER DATABASE statement failed

This problem occurs if the following conditions are true:  In SQL Server Profiler, you are running a trace on the Audit Database Management event.

Note C2 audit also collects the Audit Database Management event.  You run the following Transact-SQL query to bring an offline database online: alter database  database online.

Note This event is also included in the C2 audit trace, and it cannot be removed if you turn on the C2 audit trace. Therefore, you must turn off the C2 audit trace.
 * Run the sp_detach_db stored procedure to detatch the database, and then run the sp_attach_db stored procedure to attach the database.



STATUS
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the &quot;Applies to&quot; section.



MORE INFORMATION
For more information, 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

Keywords: kbqfe kbpubtypekc kbhotfixserver kbsql2005engine KB926335

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.