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 ‘sql server 2000’

FIX: An access violation exception may occur when you use PDH APIs to collect performance data for several instances of SQL Server at the same time

Symptoms
If you use a program that uses Performance Data Helper (PDH) APIs to collect the performance data of several instances of Microsoft SQL Server 2000 at the same time, an access violation may occur. For example, this problem occurs if you collect performance data from six or more instances of SQL Server. The performance data collection for the instances of SQL Server may also stop. Additionally, you may notice that the following registry key is created and the value of the registry key is set to 1:
HKey_Local_Machine\System\ControlSet001\Services\<InstanceOfSQLServer>\Performance\Disable Performance CountersNote The registry key is created for all the instances of SQL Server where the performance data is collected.
Resolution
Service pack informationTo resolve this problem, obtain the latest service pack for Microsoft SQL Server 2000. For more 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 hotfix 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——————————————————————————-31-May-200305:152000.80.818.078,400Console.exe27-Oct-200314:512000.80.873.0315,968Custtask.dll30-Jan-200402:592000.80.911.033,340Dbmslpcn.dll24-Apr-200312:42786,432Distmdl.ldf24-Apr-200312:422,359,296Distmdl.mdf29-Jan-200312:25180Drop_repl_hotfix.sql11-Sep-200313:562000.80.859.01,905,216Dtspkg.dll26-Aug-200306:462000.80.854.0528,960Dtspump.dll23-Jun-200309:102000.80.837.01,557,052Dtsui.dll23-Jun-200309:102000.80.837.0639,552Dtswiz.dll23-Apr-200313:21747,927Instdist.sql02-May-200312:261,581Inst_repl_hotfix.sql30-Jan-200402:592000.80.911.090,692Msgprox.dll31-Mar-200312:371,873Odsole.sql30-Jan-200402:592000.80.911.062,024Odsole70.dll30-Jan-200402:592000.80.911.025,144Opends60.dll30-Jan-200402:592000.80.911.057,904Osql.exe02-Apr-200309:452000.80.797.0279,104Pfutil80.dll04-Aug-200304:47550,780Procsyst.sql11-Sep-200311:0712,305Qfe469315.sql22-May-200309:2719,195Qfe469571.sql29-Jan-200411:471,090,380Replmerg.sql30-Jan-200402:592000.80.911.0221,768Replprov.dll30-Jan-200402:592000.80.911.0307,784Replrec.dll29-Jan-200409:542000.80.911.0159,813Replres.rll05-Sep-200310:301,087,150Replsys.sql13-Aug-200302:58986,603Repltran.sql30-Jan-200402:592000.80.911.0287,304Rinitcom.dll30-Jan-200402:592000.80.911.057,916Semnt.dll29-Jul-200306:432000.80.819.0492,096Semobj.dll31-May-200304:572000.80.818.0172,032Semobj.rll02-Jan-200406:122000.80.904.053,832Snapshot.exe09-Dec-200306:37117,834Sp3_serv_uni.sql04-Feb-200411:162000.80.913.028,672Sqlagent.dll04-Feb-200411:172000.80.913.0311,872Sqlagent.exe19-Feb-200404:322000.80.916.0168,001Sqlakw32.dll11-Mar-200415:042000.80.923.033,344Sqlctr80.dll30-Jan-200402:592000.80.911.04,215,360Sqldmo.dll07-Apr-200304:1425,172Sqldumper.exe29-Jan-200409:472000.80.911.028,672Sqlevn70.rll05-Mar-200403:432000.80.922.0180,792Sqlmap70.dll02-Sep-200313:262000.80.857.0188,992Sqlmmc.dll02-Sep-200309:332000.80.857.0479,232Sqlmmc.rll21-Oct-200310:382000.80.871.0401,984Sqlqry.dll30-Jan-200402:592000.80.911.057,920Sqlrepss.dll11-Mar-200415:052000.80.923.07,618,641Sqlservr.exe30-Jan-200402:592000.80.911.0590,396Sqlsort.dll30-Jan-200402:592000.80.911.045,644Sqlvdi.dll30-Jan-200402:592000.80.911.0106,588Sqsrvres.dll30-Jan-200402:592000.80.911.033,340Ssmslpcn.dll30-Jan-200402:592000.80.911.082,492Ssnetlib.dll30-Jan-200402:592000.80.911.025,148Ssnmpn70.dll27-Oct-200314:512000.80.873.0123,456Stardds.dll30-Jan-200402:592000.80.911.0158,240Svrnetcn.dll30-Jan-200402:592000.80.911.076,416Svrnetcn.exe30-Apr-200310:222000.80.816.045,132Ums.dll30-Jan-200402:592000.80.911.098,872Xpweb70.dll19-Jun-200400:522000.80.952.0307,784Replrec.dll19-Jun-200400:522000.80.952.07,581,777Sqlservr.exeNote Because of file dependencies, the most recent hotfix or feature that contains these files may also contain additional files.

FIX: Unable to Restore to a Point in Time in First Transaction Log Backup

Symptoms
You cannot restore to a point in time within the first transaction log backup for a database when you use SQL Server Enterprise Manager to perform the RESTORE operation.
In SQL Server 7.0, despite the value entered by the user, the GUI always defaults to the time at the end of the first transaction log.
In SQL Server 2000, the following error message occurs if you enter a point in time within the first transaction log:

The time specified is less than the minimum point in time allowed. Time corrected. After the user clicks OK to close the message box, you find that the end time of the transaction log has replaced the time entered earlier.
The subsequent execution of the RESTORE command restores the database to the end of first transaction log backup.
Resolution
SQL Server 2000To 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/EN-US/) INF: How to Obtain the Latest SQL Server 2000 Service Pack
SQL Server 7.0To resolve this problem, obtain the latest service pack for Microsoft SQL Server 7.0. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:
301511?(http://support.microsoft.com/kb/301511/EN-US/) INF: How to Obtain the Latest SQL Server 7.0 Service Pack

FIX: Transform Data Task Might Stop Responding (hang) While Importing Data From Text File

Symptoms
If you use the Transform Data Task (the data pump engine in Data Transformation Services) to import data to a SQL Server database from a text file that has rows with an invalid format, you may observe the following behavior:The Transform Data Task might stop responding (hang).CPU utilization might increase to almost 100 percent.The only way to cancel the task is to end the Mmc.exe process (if the task was run manually) or to end the Dtsrun.exe process (if the task was scheduled) by using the Windows Task Manager.
Resolution
SQL Server 2000To 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 theMicrosoft Knowledge Base:
290211?(http://support.microsoft.com/kb/290211/EN-US/) INF: How to Obtain the Latest SQL Server 2000 Service Pack
SQL Server 7.0To resolve this problem, obtain the latest service pack for Microsoft SQL Server 7.0. For additional information, click the following article number to view the article in theMicrosoft Knowledge Base:
301511?(http://support.microsoft.com/kb/301511/EN-US/) INF: How to Obtain the Latest SQL Server 7.0 Service Pack

FIX: The performance of the statement that raises an error differs from the performance of the statement that does not raise an error when you trace exception events in SQL Server 2000 on an IA-6 …

Symptoms
This article describes the following about this hotfix release:The issues that are fixed by the hotfix packageThe prerequisites for installing the hotfix packageWhether you must restart the computer after you install the hotfix packageWhether the hotfix package is replaced by any other hotfix packageWhether you must make any registry changesThe files that are contained in the hotfix package
Resolution
When you trace exception events in Microsoft SQL Server 2000 on an IA-64 computer,the performance of the statement that raises an error differs from the performance of the statement that does not raise an error.
Note For more information about how to trace exception events in SQL Server 2000, see the “More information” section.
For example, you have a statement that inserts an already existing value into a primary key column of a table. When you run the insert statement, you receive an error message that resembles the following:

Server: Msg 2627, Level 14, State 1, Line 1
Violation of PRIMARY KEY constraint ‘PK_Table1′. Cannot insert duplicate key in object ‘Table1′.
The statement has been terminated.Additionally, you can see the error in the SQL Profiler trace output. If you repeatedly run this insert statement for several hours, some executions of the statement take a much longer time to display this error message. Alternatively, you can use the SQL:StmtCompleted event class to record the duration for every execution of the statement. The duration of some executions of the statement are much longer than the duration of the rest.
This example shows a scenario in which you encounter this problem. This problem may be observed with other error numbers in addition to error 2627.
For a list of all publicly released SQL Server 2000 post-Service Pack 4 hotfixes, click the following article number to view the 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 Service Pack 4

FIX: SQLAgent Exception Occurs when the System Maintains 613, 2661 or 4709 Jobs

Symptoms
The SQLAgent process may terminate with with following error messages:

2001-01-14 19:21:11 – ! [LOG] Exception 5 caught at line 335 of file ..\src\job.c.SQLServerAgent initiating self-termination
2001-01-14 19:21:29 – + [098] SQLServerAgent terminated (forcefully)
Resolution
SQLAgent creates a memory structure to support the xp_sqlagent_enum_jobs action. With SQL Server 2000 the structure is 588 bytes plus 4 bytes for overhead. However, an incorrect CAST to a LPTSTR, instead of a LPBYTE, results in an incorrect 4 byte shift.
When the (number of created jobs on the system * 588) + 4 = NT Page boundary the incorrect 4 byte cast results in the exception.

FIX: SQL Server Does Not Run RESTOREVERIFYONLY When Scheduling a Back Up in SQL Enterprise Manager

Symptoms
If you back up a database with SQL Enterprise Manager (SEM) and you check Verify backup upon completion under the Option tab, SQL Server issues the following commands: BACKUP DATABASE and RESTORE VERIFYONLY. RESTORE VERIFYONLY checks whether the backup set is complete and whether all volumes are readable.
For example, if you back up the Pubs database to a backup device called Test, SQL server runs the following two SQL commands:

BACKUP DATABASE [pubs] TO [test] WITHINIT ,NOUNLOAD ,NAME = N’pubs backup’,NOSKIP ,STATS = 10,NOFORMAT goRESTORE VERIFYONLY FROM [test] WITHFILE = 1 ,NOUNLOAD However, if you schedule a job through the SQL Enterprise Manager to do the same database back up, SQL Server only schedules BACKUP DATABASE without the RESTORE VERIFYONLY option.
Resolution
SQL Server 2000To 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 theMicrosoft Knowledge Base:
290211?(http://support.microsoft.com/kb/290211/EN-US/) INF: How to Obtain the Latest SQL Server 2000 Service Pack
SQL Server 7.0To resolve this problem, obtain the latest service pack for SQL Server 7.0. For additional information, click the following article number to view the article in theMicrosoft Knowledge Base:
301511?(http://support.microsoft.com/kb/301511/EN-US/) INF: How to Obtain the Latest SQL Server 7.0 Service Pack