Introduction
This document was compiled by a member of SAP Active Global Support in order to provide a gathering of questions and answers from SAP SQL Server Development and Support Development to provide helpful instruction to our customers. This document is not intended to replace SAP Notes or standard Microsoft documentation. For many questions we have provided a basic answer and then pointed to an existing SAP Note or Microsoft document. Please follow the SAP Note or Microsoft document in the event of a conflict. For the present time this document is available as an attachment to SAP Note 555223: FAQ: Microsoft SQL Server. Soon it will be posted to the Service Marketplace (http://service.sap.com) where you can download it and provide feedback to the author.
Introduction.......................................................................................................................................................2 1 FAQ...............................................................................................................................................................5 IMPORTANT INFORMATION BEFORE YOU CONTINUE...........................................................................5 What are good resources for information on administering and troubleshooting SQL Server?.................5 Best practices for opening a message with SAP Support..........................................................................6 Top 5 Operational Problems to Avoid........................................................................................................6 Is There Automatic Monitoring of SAP Software?......................................................................................7 Available Training Classes and Books.......................................................................................................7 ADMINISTRATION TASKS AND QUESTIONS............................................................................................8 Why do I need environment variables defined? .......................................................................................8 What are important profile parameters for SQL Server?...........................................................................8 How do I change database parameters?...................................................................................................8 How can I move/increase/decrease datafiles?..........................................................................................8 Can I monitor a non-Basis/ WAS remote system? ....................................................................................8 How do I remove stored procedures created by the SAP kernel?.............................................................8 What do I need to know about the SAP Database Monitor?......................................................................8 What are standard jobs I need to ensure are scheduled?.........................................................................9 Where are the important SAP and Microsoft error logs physically located?..............................................9 What is the SQLDIAG utility and how do I run it?......................................................................................9 AUTHENTICATION AND ACCOUNTS USED..............................................................................................9 What are the authentication methods?......................................................................................................9 How do I change the password for the sa account?................................................................................10 How do I change passwords for accounts that connect to SQL Server?.................................................10 DATAFILES.................................................................................................................................................10 Why is the number of datafiles important?...............................................................................................10 How many data files should I create? .....................................................................................................10 What do I need to consider about the file layout?....................................................................................10 Can I just let autogrowth handle data growth needs?..............................................................................11 INSTALLATIONS/ UPGRADES/ SYSTEM COPIES...................................................................................11 What do I need to know about installing or upgrading to SQL Server 2000?..........................................11 How do I perform an SAP installation or upgrade?..................................................................................11 How do I perform a system copy?...........................................................................................................11 NETWORK PROTOCOLS...........................................................................................................................11 Which client network protocols should I configure?.................................................................................11 How do I identify the client network protocol being used by SAP?..........................................................12 How do I review/change client network protocols?..................................................................................12 SQL SERVER SERVICES...........................................................................................................................12 Is Microsoft Distribution Transaction Service needed for SAP installations?...........................................12 Is Microsoft SQL Agent need for SAP installations?................................................................................12 RECOVERY MODELS AND BACKUP/RESTORE......................................................................................12 What is the proper recovery model for me?.............................................................................................12 What should I know about backups from SAP?.......................................................................................12 What is the most critical part of backup and recovery?...........................................................................13 What do I need to know about backups from Microsoft?.........................................................................13 SERVICE, SUPPORT PACKS AND PATCHES..........................................................................................13 What are Service Packs and QFEs?.......................................................................................................13 Which Microsoft Service Packs and Hotfixes are supported by SAP? ...................................................13 Does SAP Support Microsoft Security Patches?.....................................................................................14 How do I install Microsoft Service Packs?...............................................................................................14 What are Support Packs? .......................................................................................................................14 How do I apply an SAP kernel patch?.....................................................................................................14 MULTIPLE DATABASES, sql INSTANCES AND MCOD............................................................................14 What are the differences between multiple SQL Server instances on one server, multiple databases on one server and MCOD?...........................................................................................................................14 SQL SERVER AND SAP PROGRAMMING................................................................................................15 Can I use database hints in ABAP?.........................................................................................................15 Are customer-created SQL Server triggers supported on SAP systems?...............................................15 Can I get data from a remote SQL Server?.............................................................................................15 2 Performance................................................................................................................................................16 3 Determining the cause of long SAP response times...............................................................................16 4 SQL Server..............................................................................................................................................17 SQL Server Parameters...........................................................................................................................17 Version 1.0 Page 3 of 26
Memory Configuration..............................................................................................................................17 SAP and SQL Server...............................................................................................................................17 Does reorganization help performance?..................................................................................................17 General Performance Questions.............................................................................................................17 Do you have DBCC CHECKDB job scheduled during business hours or critical processing times?...17 Are auto create and auto update statistics turned on?.........................................................................17 Are page locks turned off for frequently updated tables? ....................................................................18 Is tempdb sized appropriately?............................................................................................................18 What is the difference between blocking and deadlocking?.................................................................18 SQL Server Myths....................................................................................................................................18 Parallelism always improve performance.............................................................................................18 Updating statistics manually improves performance............................................................................18 Reorganizing an index will increase query performance......................................................................18 SQL Server Is Not an Enterprise Database as Theres No Row-Level Locking...................................18 5 I/O Performance......................................................................................................................................19 SQL Server IO Tools................................................................................................................................19 Windows IO Tools....................................................................................................................................19 Submitting a Message to Support Regarding IO.....................................................................................20 6 General Troubleshooting.............................................................................................................................21 7 Basic STEPS...........................................................................................................................................21 8 Windows Event Log.................................................................................................................................21 9 SQL Server Error Log..............................................................................................................................21 10 Trace flags.............................................................................................................................................22 11 SAP Transactions to use for troubleshooting........................................................................................22 12 Specific Troubleshooting...........................................................................................................................23 13 Excessive Transaction Log Growth.......................................................................................................23 14 SQL Errors.............................................................................................................................................23 15 Cluster troubleshooting..........................................................................................................................24 16 Backup problems/ FAILURES...............................................................................................................24 17 Post restore activities:...........................................................................................................................24 18 Suspect Database.................................................................................................................................24 19 SICK Database...................................................................................................................................25 20 Hanging System....................................................................................................................................25 21 Diagnosing deadlocks...........................................................................................................................25 22 Upgrading 7.0 to 2000 or Installing 2000...............................................................................................25 23 Database connectivity problems............................................................................................................25 24 POST SYSTEM COPY problems..........................................................................................................25 25 ST04 BUFFER RATIO > 100%.............................................................................................................26
1 FAQ
IMPORTANT INFORMATION BEFORE YOU CONTINUE
What are good resources for information on administering and troubleshooting SQL Server?
For SQL Server, the primary resource is SQL Server Books online. Unless you changed the default installation, it was automatically installed with the database. There is an updated copy from January 2004 you can download from Microsoft here. For both Windows and SQL Server , the Microsoft Knowledge Base is an excellent source troubleshooting. For example, suppose you find the following error in your System Event Log:
Go to the Microsoft Knowledge Base to search for more information. First use the search phrase event id 4. As with any search, start with the widest criteria (all products, full text) and narrow the criteria if too many results are returned. Also, search with a variety of criteria to receive different matches, e.g., one search with the exact phrase event ID 4, one search for all the words event id 4 e100B, Adapter Link Down, etc. For SAP software, your best resource for bug fixes is SAPNet R/3 Frontend (formerly called OSS). Search for SAP Notes using the same general recommendations we gave above for the Microsoft site, i.e., use a variety of terms and searching methods to evaluate the best amount of information. For general SAP software information, the website SAP Help Portal is essential. Its really just the SAP help files posted online, but the search engine is great and is invaluable. You can search it to find out the proper usage of a transaction, what a report is used for, standard administration tasks, etc. Often searching the functional information is invaluable for a Basis person to understand what the functional staff is doing on the system.
2.
3.
4.
This book offers you expert information about SAP database administration using Microsoft SQL Server 2000. The book addresses all aspect of SQL Server and the SAP system that play a part in coordinating the two systems productively. The author works for SAP Active Global Support. Inside Microsoft SQL Server 2000 by Kalen Delaney The book focuses on SQL Server architecture and the internal workings of SQL Server. SAP Performance Optimization Guide, Third Edition by Thomas Schneider This is a step-by-step performance optimization and monitoring guide. The author works for SAP Active Global Support. See a detailed Table of Contents here: http://www.sap-press.com/H951.html
Where are the important SAP and Microsoft error logs physically located?
The SAP dev traces and system logs are found in /usr/sap/<sid>/<instancetype><system number>/work. For example, /usr/sap/PRD/ DVEBMGS00/work. They will be found on the drive where you installed SAP. To find the SQL Server Error Log, follow the directions in the SQL Server Books Online section Viewing Error Logs. Double-click the Current Log and one of the first lines will tell you the log file name with the full path in case you need to send the logs to SAP. You could also view the log from inside SAP by ST04 -> Detail Analysis -> Error Logs. To attach the Windows Event Logs to an SAP support message you will need to first save a local copy. Open Event Viewer via Start -> Control Panel -> Administrative Tools. Then right-click the log name in the left frame (for example, System) and choosing Save log file as. You can save it in any of the formats listed. To open a locally saved log file with the extension .evt you need to open Event Viewer. Then right-click somewhere in the right frame and choose Open Log File Navigate to the locally saved copy and choose it. You must specify whether it is a System, Application or Security log.
DATAFILES
Why is the number of datafiles important?
SQL Server databases store the data in datafiles which are contained in filegroups. SAP does not support user-created filegroups for an SAP database, only the initially created Primary group. See the SQL Server Books Online section Default Filegroups. Within that Primary filegroup, you must create datafiles to contain the SAP data and the number of datafiles created. SQL Server uses proportional fill to spread the data between the datafiles according to eachs freespace. This is called the proportional fill strategy. So you want to have several files each with free space available for the IO load to be spread out. If you only had one datafile then either the physical disks themselves would be overloaded and cause a bottleneck or the datafile itself would become a bottleneck due to datafile header contention. The SQL Server Books Online gives an excellent example how SQL Server would fill two files, see the section titled Using Files and Filegroups. The example is important also because it emphasizes the freespace is how SQL Server decides where the data will go. To reach the best distribution across multiple files they should be created all at the same size and, when increases are needed, all increased by the same amount. This will allow you to keep an approximately equal amount of freespace in each file so the data is well distributed.
Production database transaction log files Temporary database datafiles Temporary database log Windows Swap files
It is acceptable to have multiple production database datafiles on the same disks or have multiple temporary database datafiles on the same disks. Just dont have production database datafiles on the same disks as the temporary database datafiles. Dont rely on the logical drives letters (D:, E:, F:, etc.) as proof that the datafiles are on separate physical disks. The hardware layer is invisible to Windows and the hardware could have the same physical disks mapped to drives E: and F:. Hardware vendors have software to analyze the physical disk allocation.
NETWORK PROTOCOLS
Which client network protocols should I configure?
Simply, on the database server you should use Named Pipes whereas all application servers should use TCP/IP. For clustered servers, see the SAP Note provided below for additional information depending on the cluster configuration.
Additionally, on the database server we do not recommend having the setting Enable Shared Memory Protocol checked. More information is available in SAP Note 208632: TCP/IP network protocol for MSSQL.
same name as the system SID. For example, you install an MCOD system with a CRM SID of CRP and an R/3 SID of PRD and would like to see the client list for each in SQL Query Analyzer. You would have to execute 2 separate SQL statements like this: Select * from crp.t100 Select * from prd.t100 One backup will cover all schemas since they are installed in one database and all schemas could be restored to one point in time. Again, they will share the same memory block and have the same database parameters because they are in the same database. They will also share datafiles and transaction log since they are in the same database. Since R/3 Enterprise (4.7) all SQL Server systems are automatically installed as a schema under the user <sid>. There are several other sources of information. The alias /mcod has more information and so do the following SAP Notes: o SAP Note 374276: Single database, multiple schemata o SAP Note 171929: Several R/3 Systems on one SQL Server 7.0 o SAP Note 388638: Multpl. componts. on 1 DB (MCOD) MSSQL installation
2 Performance
3 DETERMINING THE CAUSE OF LONG SAP RESPONSE TIMES
For standard SAP performance tuning the best resource is SAP R/3 Performance Optimization by Thomas Schneider, available at many web stores and SAP Press. This is the best resource and the section below is a small part of the analysis roadmaps detailed in the book and has been greatly simplified in an attempt to provide a basic roadmap for novices. Many important topics, like Memory Management, have been completely skipped as they cannot be simplified. The first step is to identify the average dialog response time of the system. For an OLTP system like R/3, CRM, etc, the time should be less than 1,000 ms. SAP Support normally starts an analysis by viewing the average dialog response time for the total system for the prior week. Transaction ST03N -> Change the view from Administrator to Expert Mode -> Double click the prior weeks date under Workload Total Week. The Workload Overview will appear in the right frame. The average dialog response time will be in the column titled Time. o The average database time should not be > than 40% of average dialog time. Be careful with this rule, if the overall response time is very good than the database time can easily be greater than 40% but still not a concern. Use per transaction analysis to see if specific transactions have long database times and perform SQL Statement Analysis with ST04 to identify expensive statements on the database. o Load time should be < 50 milliseconds If its is greater than 50 your program buffer may be too small and need to be enlarged. Use ST02 to analyze the program buffer and determine if you have enough free memory to enlarge the buffer. o Wait time should be < 50 milliseconds Are there enough work processes? Is something consuming too many work processes (parallel program or CPIC calls)? Use SM50 to see if you ever have dialog processes in the waiting status. There should always be a few available on each instance. Another performance tool is to use SM66/SM50 to watch active work processes. First, you want to ensure that you always have some work processes in the status waiting so that you have processes available when needed. Secondly, you can analyze the performance by analyzing the running processes as below: Processes in running status for a long time (manual screen refreshes over several minutes) o Are they stuck in a long running sequential read? Trace the transaction with ST05 to determine the reason for the long read time. o Are there exclusive locks? You can view this many ways. (1) SM66 (with flag checked in Settings) (2) ST04 -> Detail Analysis -> Exclusive Lockwaits or (3) transaction DB01. o Is it in load report or have semaphore 1? Use ST02 to see if the program buffer is too small. o Is it in roll in/roll out or semaphore 6? Use ST02 to review extended memory and roll buffer. o Is it in PRIV? Use St02 and ST03 to see who is consuming extended memory. May not be the PRIV process. o Is it in CPIC? Is the RFC destination server too busy and causing a bottleneck on your system? Performing a SQL Cache analysis of slow SQL statements is complex. We have provided the central SAP Note 155413: Analysis of slow SQL statements. In addition, there are a few other Notes which document problems with specific tables: o Slow access to the CE4xxxx tables SAP Note 443404: Performance: CE4xxxx tables on SQL server SAP Note 35288: Profitability Analysis: Technical Documentation
o o
SAP Note 499858: Storage parameter maintenance with MS SQL Server SAP Note 540881: Index for accessing VBBE, ATP_VBBE SAP Note 305909: Performance of STXH in SELECT_TEXT on SQL Server (DB2)
4 SQL SERVER
SQL Server Parameters
SQL Server Parameters should remain at the default installed values unless indicated otherwise in SAP Note 327494: Configuration Parameters for SQL Server 2000 or by SAP Active Global Support. If you are unsure of the default value for a database parameter, see the SQL Server Books Online section titled Setting Configuration Options. Many customers have changed the default values for Priority Boost, Set Working Size and Max Degree of Parallelism based on general internet advice regarding performance. SAP has tested these parameters intensively and has determined that all three settings should be disabled. This means that Priority Boost and Set Working Size would be set to 0 and Max Degree of Parallelism would be set to 1 (setting it to one means processes can only use 1 processor). The only exception to this rule so far is that Parallelism is at times good to enable in BW or APO systems. See the SAP Note mentioned above for the details.
Memory Configuration
If the database server also has an SAP instance running you need to ensure that the database and SAP are not competing for memory. Make sure that SQL Server is using a fixed amount of memory, that the SAP parameter PHYS_MEMSIZE is set to restrict its amount of memory and that some extra memory is left over for Windows. See SAP Note 327494: Configuration Parameters for SQL Server 2000 for more detail. If this is not a central system (one physical server with the database and SAP and no other application servers) it is best to allocate more memory to SQL Server and restrict the SAP instance. This would also mean you have to be careful how many users you allow on the SAP instance on the database server as well.
5 I/O PERFORMANCE
IO problems can cause drastic performance problems and also temporary or periodic problems. In this section we have listed the most common problems weve seen and a brief listing of indicators you can check to help you see you possibly have a problem. If yes, we recommend gathering the data that you think shows the IO problem and submitted a message to BC-DB-MSS for Support to review. Confirming an IO problem is not always easy and actually identifying the IO problem is often very difficult. The most common problems see are: 1. Controllers are configured improperly. The controller sits between the Windows server and the disk array or storage system and will have to be examined by a hardware partner. Real-life examples of poor controller configuration are: a. There are two controllers meant to supply load-balancing. However, one controller is configured as a failover for the first so in reality there is only one controller working and it is overloaded. b. Read caching was disabled on the controller so its performance was not as good as it should have been. 2. The disk system has too few spindles. Some customers have a disk system that is just too small for the amount of data throughput an SAP system requires. Although there is plenty of total storage space it is spread across devices with too few spindles to platters so the data just cant be retrieved quickly enough. 3. IO intensive files are on the same physical disks. Files of the following types should each be on separate physical disks: a. Database data files b. Database transaction log c. Temporary database data files d. Temporary database transaction log e. Operating system swap files NOTE: Although it may appear the files are separated according to Windows (e.g., files are on separate G:, H:, I: and L: drives) that does not mean they are separated at the storage level. So even though the files appear separate to Windows they could actually be on the same physical disks. All hardware vendors have tools to see which physical drives in the storage system are mapped to a logical drive in Windows, they can provide you with this information. 4. Disk file system cluster size is too small. For best performance the disks should be formatted with a 64KB cluster size, although 4K, 8K, 16K are acceptable. At this time we do not recommend reformatting your disks unless they are significantly different (for example, if they are at 64 bytes or 256 KB). See the SQL Server Books Online section titled File Systems. There are SQL Server tools and Windows tools to help you review IO performance.
Windows IO Tools
System Monitor, called Performance Monitor in NT 4.0, is a Microsoft tool that you can configure to capture performance data. Before trying to do IO disk performance analysis you must enable disk counters by executing diskperf y in a Windows command prompt. A server reboot is then needed to activate the change.
System Monitor allows you to log the counters for future evaluation and analysis by yourself or SAP. We recommend reading the Windows Help files as System monitor is a complex tool. Open the Help files at Start -> Help and then search for System Monitor. Note: Be careful when enabling System Monitor. Enabling too many counters for a long period of time can cause the log to grow rapidly and affect system performance. Watch the file carefully when first starting a collection to ensure it does not grow too rapidly. You can also set a maximum file size but the file will overwrite itself. Many people (and standard Windows documentation) use the counters PhysicalDisk: % Disk Time and PhysicalDisk: Avg. Disk Queue Length to analyze disk performance. We have found that these counters are not always reliable when observing an SAP system since the throughput is so demanding. You may have a high disk queue number but if the results are consistently served in a millisecond then the length of the queue isnt so important. The counters we would evaluate for IO performance are: PhysicalDisk: Avg disk sec / read PhysicalDisk: Avg disk sec / transfer PhysicalDisk: Avg disk sec / writes These values provide a time analysis which is the more crucial information. These are snapshot values which is why you want to configure System Monitor to log the counters for a period of time. If a hardware vendor uses a proprietary tool to check the disk throughput you should turn on System Monitor logging at the same time. Some vendor tools calculate the time after the request passes the controller and to the disk. With the controller itself often being a bottleneck the Windows counters will reveal the time that the operating system has to wait for the data. If this value is high but the vendor tool has low numbers then you should investigate the controllers.
6 General Troubleshooting
7 BASIC STEPS
Ensure the client libraries and database server are on the same SQL Server version (especially SQLOLEDB.DLL and DBNETLIB.DLL). Since WAS 6.20 you can easily check the dll version by reading the contents of the database table MSSDWDLLS. Prior to that you have to check it manually. Ensure the SAP kernel and DBSL are the latest version. Review SAP and MS logs (see below). Ensure your database parameters are set properly according to SAP Note 327494: Configuration Parameters for SQL Server 2000. Search for SAP fixes at http://service.sap.com/notes. Search for Microsoft fixes in the Knowledge Base at http://support.microsoft.com/default.asp.
10 TRACE FLAGS
Trace flags are a valuable tool for in-depth analysis. But they should never be added unless SAP Support or Microsoft directs you to use them.
12 Specific Troubleshooting
13 EXCESSIVE TRANSACTION LOG GROWTH
See the following SAP Notes, this is an easy error to avoid: o SAP Note 307911: Transaction Log Filling Up in SQL Server 7.0 o SAP Note 400251: Index creation fills up transaction log o SAP Note 421644: SQL error 9002: The transaction log is full
14 SQL ERRORS
0 o 11 o 156 o In a SQL command you used a reserved keyword of SQL Server. For example, when you created a backup device you named it database. This is a keyword in SQL Server so backups trying to use this device name will fail with a syntax error. See the SQL Server Books Online sections titled Error 156 and Reserved Keywords for more information. SAP Note 392892: DBIF_RSQL_SQL_ERROR (SQL error 0 or 11) SAP Note 392892: DBIF_RSQL_SQL_ERROR (SQL error 0 or 11)
169 o SAP Note 110143: Field must not appear more than once in ORDER-BY 207/ 208 o SAP Note 459676: MSSQL is case-sensitive o SAP Note 65009: SQL208 o SAP Note 555623: SQL error 208 or 2812 in a SQL script 446 o SAP Note 505906: SQL error 446: Cannot resolve collation conflict 601 o SAP Note 607689: SQL Server 2000: Database Error 601 o SAP Note 429255: 601 on DDNTT, 823 and 1453 in SQL Error log in SQL 7.0 SP2 o SAP Note 565708: SQL Server: database error 601 o SAP Note 142731: DBCC checks of SQL server 605 o SAP Note 142731: DBCC checks of SQL server 644 o SAP Note 142731: DBCC checks of SQL server 823 o SAP Note 429255: 601 on DDNTT, 823 and 1453 in SQL Error log in SQL 7.0 SP2 o SAP Note 142731: DBCC checks of SQL server 1205 o SAP Note 565710: SQL Server: Database error 1205 (deadlock) 1453 o SAP Note 429255: 601 on DDNTT, 823 and 1453 in SQL Error log in SQL 7.0 SP2 2511 o SAP Note 142731: DBCC checks of SQL server 2714 o SAP Note 460271: There is already an object named ... 2750 o SAP Note 137821: SQL2750, decimal fields with more than 28 places 2812 o SAP Note 555623: SQL error 208 or 2812 in a SQL script 3023 (SQL 7.0) o SAP Note 182170: SQL error 3023 when creating an index 8115
o SAP Note 429805: SQL error 8115 8645 o SAP Note 206694: SQL 7.0 Error 8645 {Insufficient Memory Resources} 8928 o SAP Note 142731: DBCC checks of SQL server 8944 o SAP Note 142731: DBCC checks of SQL server 8952 o SAP Note 142731: DBCC checks of SQL server 8976 o SAP Note 142731: DBCC checks of SQL server 9002 t-log is full o SAP Note 421644 - SQL error 9002: The transaction log is full o SAP Note 400251: Index creation fills up transaction log o SAP Note 307911: Transaction Log Filling Up in SQL Server 7.0 9004 o SAP Note 325443: SQL error 9004
15 CLUSTER TROUBLESHOOTING
If you have problems installing a cluster node on a server that previously had a SQL Server installation, the original SQL Server may not have uninstalled completely. Open a message to SAP for Supports assistance in checking the registry and file system. Cluster installations are not support on named instances. You must install to the default instance and must not later install any other SQL Server instances on that database server. There are several information sources already for cluster installations. From SAP: SAP Note 413553: SQL 2000 cluster set-up fails SAP Note 112266: R/3 + MS cluster server: Frequent questions + hints SAP Note 209596: Setting up Microsoft SQL Server 2000 From Microsoft: Q 233332: How To Run SQLDIAG On a Clustered/Virtual SQL Server Q 254321: Clustered SQL Server Do's, Don'ts, and Basic Warnings Q 254593: Troubleshooting SQL Cluster Wizard Failures
18 SUSPECT DATABASE
See SAP Note 81692: Suspect Database
19 SICK DATABASE
See SAP Note 126973: SICK messages with MS SQL Server
20 HANGING SYSTEM
SAP Note 155402: Analysis of hanging situations SAP Note 541256: Hangman 3.0
21 DIAGNOSING DEADLOCKS
For a full explanation of blocking locks versus deadlocks, see the SQL Server Books Online section Troubleshooting Locking. There are a few different resources for troubleshooting deadlocks. Microsoft provides instruction in the SQL Server Books Online section Deadlocking. SAP has many Notes regarding deadlocking. The first SAP Note you should read for detailed instructions on how you can trace a deadlock is SAP Note 32129: Setting up deadlock tracing for SQL-Server. An FAQ which answers many additional questions is SAP Note 111291: FAQ: SQL server analysis and avoidance of deadlocks. We also have compiled a list of known SAP Notes that have a fix for deadlocks on specific tables. See SAP Note 565710: SQL Server: Database error 1205 (deadlock). If the deadlock has only SAP objects then you should open a message for help from Support. Provide the deadlock information from the SQL Error Log and everything else according to best practices. If any one or more of the objects are a customer table (begins with a Y or Z) then it is custom code causing the deadlock and your developers need to evaluate the program causing the deadlock. Ways to reduce the possibility of deadlocks are: 1. Keep the transaction short 2. Always change all objects in the same order 3. If the code is accessing a custom object then make sure the clustered index is appropriate for the update statement.