SQL Server Q&A

As a software engineer, I focus on .NET, especially asp.net, C#, WCF and so on, and I am also very interested in Search Engine Optimization.

Entries Tagged ‘Time’

FIX: SQL Enterprise Manager Restore to Point in Time Does Not Stop at Requested Time and the Database is Left in a Loading State

Symptoms
If all of the following conditions are true, a restore to a point-in-time leaves the database in a loading state (unrecovered) and does not stop at the requested time: You perform the restore through SQL Enterprise Manager (SEM).You restore one backup file (device) at a time, and you specify a “Point in Time” to stop in the last transaction log you restore.
Resolution
A restore to a point-in-time from Enterprise Manager does not stop at the requested time because Enterprise Manager automatically changes the point-in-time value to the backup time of the last transaction log.
A mechanism in the restore to a point-in-time leaves the database in a loading state if there are no log entries after the time you specify, to allow you to apply more transaction logs if you want.

FIX: Some Named Pipes features are not disabled after you disable the Named Pipes protocol

Symptoms
When you use Server Network Utility to disable Named Pipes as a communication protocol, the following Named Pipes-based features are not disabled: Backup … To Pipe …Restore … From Pipe …Console.exeThis problem may also occur if the DISABLENETWORKPROTOCOLS parameter is used by SQL Server Desktop Engine(also known as MSDE 2000) Service Pack 3 (SP3).
Resolution
Service pack informationTo resolve this problem, obtain the latest service pack for Microsoft SQL Server 2000. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:
290211?(http://support.microsoft.com/kb/290211/) How to obtain the latest SQL Server 2000 service pack
Hotfix informationThe English version of this fix 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 tool in Control Panel.

DateTimeVersionSizeFile name——————————————————————-06-May-200303:162000.80.818.078,400Console.exe08-May-200304:182000.80.818.029,244Dbmslpcn.dll25-Apr-200302:12786,432Distmdl.ldf25-Apr-200302:122,359,296Distmdl.mdf30-Jan-200301:55180Drop_repl_hotfix.sql07-Apr-200319:152000.80.801.01,557,052Dtsui.dll24-Apr-200302:51747,927Instdist.sql03-May-200301:561,581Inst_repl_hotfix.sql08-Feb-200306:402000.80.765.090,692Msgprox.dll01-Apr-200302:071,873Odsole.sql05-Apr-200301:462000.80.800.062,024Odsole70.dll02-Apr-200321:482000.80.796.057,904Osql.exe02-Apr-200323:152000.80.797.0279,104Pfutil80.dll04-Apr-200321:271,083,467Replmerg.sql04-Apr-200321:532000.80.798.0221,768Replprov.dll08-Feb-200306:402000.80.765.0307,784Replrec.dll05-May-200300:051,085,874Replsys.sql08-May-200304:182000.80.818.0492,096Semobj.dll05-May-200300:242000.80.818.0172,032Semobj.rll16-Apr-200322:39115,892Sp3_serv_uni.sql08-May-200304:182000.80.818.04,215,360Sqldmo.dll07-Apr-200317:4425,172Sqldumper.exe19-Mar-200318:202000.80.789.028,672Sqlevn70.rll24-Apr-200305:392000.80.811.0176,696Sqlmap70.dll08-Feb-200306:402000.80.765.057,920Sqlrepss.dll08-May-200304:192000.80.818.07,540,817Sqlservr.exe08-Feb-200306:402000.80.765.045,644Sqlvdi.dll08-May-200304:182000.80.818.029,244Ssmslpcn.dll08-May-200304:182000.80.818.082,492Ssnetlib.dll08-May-200304:182000.80.818.025,148Ssnmpn70.dll08-May-200304:182000.80.818.0158,240Svrnetcn.dll05-May-200300:092000.80.818.076,416Svrnetcn.exe30-Apr-200323:522000.80.816.045,132Ums.dll28-Feb-200301:342000.80.778.098,872Xpweb70.dllNote Because of file dependencies, the most recent hotfix or feature that contains these files may also contain additional files.

FIX: Inserting Unicode data into SSCE causes SQL Server CE to stop responding or causes an exception error

Symptoms
Inserting certain Unicode strings into a SQL Server 2000 Windows CE (SSCE) table might cause an SQL INSERT command to fail with an application error, or the application might stop responding (hang) while other programs remain responsive. The symptoms of the problem can vary, but may include messages similar to:

Application <Executable file name> has performed an illegal operation and will be shut down. Fatal Exception 0xC0000005
Resolution
A supported fix is now available from Microsoft, but it is only intended to correct the problem that is described in this article. Apply it only to computers that are experiencing this specific problem.
To resolve this problem, contact Microsoft Product Support Services to obtain the fix. For a complete list of Microsoft Product Support Services phone numbers and information about support costs, visit the following Microsoft Web site:
http://support.microsoft.com/default.aspx?scid=fh;EN-US;CNTACTMS(http://support.microsoft.com/default.aspx?scid=fh;en-us;cntactms)NOTE: In special cases, charges that are ordinarily incurred for support calls may be canceled if a Microsoft Support Professional determines that a specific update will resolve your problem. The usual support costs will apply to additional support questions and issues that do not qualify for the specific update in question.
The English version of this fix has the file attributes (or later) 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 tool in Control Panel.
Microsoft SQL Server 2000 Windows CE Edition 2.0

DateTimeVersionSizeFile name—————————————————————–15-Apr-200314:152.0.5214.01,403,972 bytesSsce20.dllARM
Microsoft SQL Server 2000 Windows CE Edition 1.1

DateTimeVersionSizeFile name—————————————————————–26-Feb-200320:441.1.5026.01,258,496 bytesSsce10.dllARMNote Because of file dependencies, the most recent hotfix or feature that contains the files may also contain additional files.

FIX: Indexed View May Cause a Handled Access Violation in CIndex::SetLevel1Names

Symptoms
A query based on an indexed view may cause a handled access violation exception in the CIndex::SetLevel1Names function and end the connection of the client
that submitted the query. Additionally, messages similar to the following are written
to the SQL Server error log:

2002-12-30 13:17:01.99 spid51 Using ‘dbghelp.dll’ version ‘4.0.5′
*Stack Dump being sent to C:\Program Files\Microsoft SQL Server\MSSQL\log\SQL00001.dmp
2002-12-30 13:17:01.99 spid51 Error: 0, Severity: 19, State: 0
2002-12-30 13:17:01.99 spid51 SqlDumpExceptionHandler: Process 51 generated fatal exception c0000005 EXCEPTION_ACCESS_VIOLATION. SQL Server is terminating this process..
Resolution
Service pack informationTo resolve this problem, obtain the latest service pack for Microsoft SQL Server 2000. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:
290211?(http://support.microsoft.com/kb/290211/) How to obtain the latest SQL Server 2000 service pack
Hotfix information The English version of this fix has the file attributes (or later) 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 tool in Control Panel.

DateTimeVersionSizeFile name————————————————————————-17-Jan-200220:452000.80.568.029,244 bytesDbmslpcn.dll30-Aug-200213:08786,432 bytesDistmdl.ldf30-Aug-200213:082,359,296 bytesDistmdl.mdf11-Dec-200209:50180 bytesDrop_repl_hotfix.sql02-Jul-200207:352000.80.650.0107,088 bytesImpprov.dll11-Dec-200209:501,402 bytesInst_repl_hotfix.sql19-Jul-200208:56774,516 bytesInstdist.sql20-Aug-200208:242000.80.679.0111,172 bytesLogread.exe15-Dec-200215:212000.80.717.090,692 bytesMsgprox.dll06-Apr-200218:082000.80.606.062,024 bytesOdsole70.dll02-Jan-200217:5918,185 bytesQfe356326.sql20-Aug-200208:472000.80.679.0135,748 bytesQrdrsvc.exe26-Aug-200214:492000.80.679.0406,088 bytesRdistcom.dll03-Oct-200117:36437,302 bytesReplcom.sql20-Aug-200208:332000.80.679.0152,136 bytesReplmerg.exe25-Nov-200213:431,004,990 bytesReplmerg.sql15-Dec-200215:212000.80.717.0221,768 bytesReplprov.dll15-Dec-200215:212000.80.717.0303,688 bytesReplrec.dll03-Oct-200117:36986,906 bytesReplsys.sql03-Oct-200117:36881,228 bytesRepltran.sql26-Aug-200214:492000.80.679.0283,208 bytesRinitcom.dll16-Sep-200214:31390,045 bytesSecurityhotfix.sql26-Aug-200214:492000.80.679.028,672 bytesSqlagent.dll26-Aug-200210:392000.80.679.0311,872 bytesSqlagent.exe28-Aug-200208:322000.80.679.049,152 bytesSqlagent.rll26-Aug-200214:492000.80.679.053,824 bytesSqlcmdss.dll28-Aug-200208:402000.80.679.012,288 bytesSqlcmdss.rll24-Oct-200209:372000.80.695.0176,696 bytesSqlmap70.dll27-Dec-200221:392000.80.721.07,471,185 bytesSqlservr.exe01-Nov-200210:562000.80.698.045,644 bytesSqlvdi.dll17-Jan-200220:452000.80.568.029,244 bytesSsmslpcn.dll19-Dec-200216:552000.80.719.082,492 bytesSsnetlib.dll19-Dec-200218:092000.80.720.025,148 bytesSsnmpn70.dll06-Apr-200218:082000.80.606.070,208 bytesXplog70.dll06-Apr-200218:082000.80.606.053,828 bytesXpqueue.dll06-Apr-200218:082000.80.606.0156,228 bytesXprepl.dll11-Jul-200217:002000.80.658.0279,104 bytesXpstar.dll16-Sep-200215:122000.80.686.098,872 bytesXpweb70.dll NOTE: Because of file dependencies, the most recent hotfix or feature that contains the files may also contain additional files.

FIX: CPU utilization may approach 100 percent on a computer that is running SQL Server 2000 every 49.7 days

Symptoms
This article describes the following about this hotfix release: The issues that are fixed by this hotfix packageThe prerequisites for installing the hotfix packageInformation about whether you must restart the computer after you install the hotfix packageInformation about whether you must make any registry changes The files that are contained in the hotfix package
Resolution
Consider the following scenario. You have a SQL Server 2000 service that is running on a computer that has a system time thatis approaching a multiple of 49.7 days from the time when the operating system is restarted. Around this period, you back up a database at least one time, or you restore a database at least one time. In this scenario, CPU utilization may approach 100 percent after the backup operation is complete or after the restore operation is complete. After approximately 15 minutes or less, CPU utilization automatically decreases.
If you back up the database or restore the database when CPU utilization approaches 100 percent, CPU utilization appears to decrease.
Note This problem appears to occur more frequently on Itanium-based computers than on x86-based computers. This problem is very noticeable on the SQL Server servers that perform backup operations or restore operations around this 49.7 day interval.
For a list of all publicly released SQL Server 2000 Post-Service Packhotfixes, see the following article in the Microsoft Knowledge Base:
894905?(http://support.microsoft.com/kb/894905/) Cumulative list of the hotfixes that are available for SQL Server 2000 SP4

FIX: An access violation occurs intermittently when you run an application that uses SQL Server 2005 service broker or SQL Server 2008 service broker

Symptoms
When you run an application that uses Microsoft SQL Server 2005 service broker or Microsoft SQL Server 2008 service broker, an access violation occurs intermittently. Then, error messages that resemble the following arelogged in the SQL Server error log file:

<Date Time>,spid76,Unknown,Service Broker needs to access the master key in the database ‘<Database Name>’. Error code:25. The master key has to exist and the service master key encryption is required.
<Date Time>,spid22s,Unknown,*
<Date Time>,spid22s,Unknown,* Access Violation occurred reading address 0000000000000000
<Date Time>,spid22s,Unknown,* Exception Code = c0000005 EXCEPTION_ACCESS_VIOLATION
<Date Time>,spid22s,Unknown,* Exception Address = 0000000002B8FA73 Module(sqlservr+0000000001B8FA73)
<Date Time>,spid22s,Unknown,*
<Date Time>,spid22s,Unknown,*
<Date Time>,spid22s,Unknown,*
<Date Time> spid 22
<Date Time>,spid22s,Unknown,* BEGIN STACK DUMP:
<Date Time>,spid22s,Unknown,*
<Date Time>,spid22s,Unknown,* *******************************************************************************
<Date Time>,spid22s,Unknown,SqlDumpExceptionHandler: Process 22 generated fatal exception c0000005 EXCEPTION_ACCESS_VIOLATION.
SQL Server is terminating this process.
<Date Time>,spid22s,Unknown,***Stack Dump being sent to C:\Microsoft SQL Server\MSSQL.1\MSSQL\LOG\SQLDump0001.txt
<Date Time>,spid22s,Unknown,An error occurred in the Service Broker internal activator while trying to scan the user queue ‘<User Queue>’ for its status. Error: 2905<c/> State: 2.These error messages describe the following sequence of events. An error occurs when SQL Server 2005 or SQL Server 2008 accesses the master key. This error causes the access violation. Additionally, other errors occur when SQL Server 2005 or SQL Server 2008 tries to scan the user queue.
Note A mini-dump file is generated in the SQL Server logfolder.
Resolution
This problem occurs because of a race condition between the alter operation for a queue whose status is “on” and the drop operation for the same queue. If the drop operation succeeds, the access violation occurs. Additionally, the queue cannot be scanned successfully aspart of the alter operation.