SQL DBA Blog: Home

  • SQL Server Version Upgrade Runbook: Side-by-Side and In-Place

    🔧Part of the DBA-Tools Project, copy/paste SQL Server scripts and health checks.In: Migration & Deployment There are two ways to upgrade a SQL Server version, and the choice is really a choice about what your rollback looks like. Side-by-side gives you a rollback that consists of pointing the application back at a server which is…

    Read More


  • SQL Server Migration Runbook: Availability Groups and Failover Clusters

    🔧Part of the DBA-Tools Project, copy/paste SQL Server scripts and health checks.In: Migration & Deployment Migrating a highly available instance is not one job, it is two different jobs that people frequently confuse. An Availability Group migration adds replicas and fails over. A Failover Cluster Instance migration builds a new cluster and cuts over. The…

    Read More


  • SQL Server Migration Runbook: Standalone Instance

    🔧Part of the DBA-Tools Project, copy/paste SQL Server scripts and health checks.In: Migration & Deployment Moving a standalone SQL Server instance to new hardware is the most common migration there is, and the one most often done from memory. The databases are the easy part. What catches people is everything around them: logins that arrive…

    Read More


  • Kerberos vs NTLM in SQL Server: Best Practices

    Every Windows-authenticated connection to SQL Server uses one of two schemes, and most teams could not say which without looking. That is usually fine, right up until a linked server double-hop fails, a security baseline starts restricting NTLM, or an SSPI error appears and nobody knows what “normal” looked like. This post is the five-minute…

    Read More


  • The SELECT Permission Was Denied on the Object (Error 229)

    🚨Part of the SQL Server Errors series, the exact messages and what actually causes them. The errorMsg 229  ·  Level 14  ·  State 5 The SELECT permission was denied on the object ‘RlsOrders’, database ‘DemoDatabase’, schema ‘dbo’. Msg 229, Level 14, State 5 ⚡The message already names object, schema and database. Look for a DENY…

    Read More


  • Could Not Open a Connection to SQL Server: Error 53 and Named Pipes Error 40

    🚨Part of the SQL Server Errors series, the exact messages and what actually causes them. The errorOS error 53  ·  Named Pipes Provider  ·  error 40 Named Pipes Provider: Could not open a connection to SQL Server [53]. A network-related or instance-specific error has occurred while establishing a connection to SQL Server. The server was…

    Read More


  • SSPI Handshake Failed in SQL Server (Error 17806)

    🚨Part of the SQL Server Errors series, the exact messages and what actually causes them. The errorMsg 17806  ·  Level 20  ·  State 14 SSPI handshake failed with error code 0x8009030c, state 14 while establishing a connection with integrated security; the connection has been closed. Msg 17806, Level 20, State 14 ⚡Clock first: five minutes…

    Read More


  • Violation of PRIMARY KEY Constraint and Cannot Insert Duplicate Key (Errors 2627 and 2601)

    🚨Part of the SQL Server Errors series, the exact messages and what actually causes them. The errorMsg 2627 / 2601  ·  Level 14  ·  State 1 Violation of PRIMARY KEY constraint ‘PK_ErrDemoPk’. Cannot insert duplicate key in object ‘dbo.ErrDemoPk’. The duplicate key value is (1). Msg 2627, Level 14, State 1 ⚡Half of these are…

    Read More


  • The Server Principal Is Not Able to Access the Database (Error 916)

    🚨Part of the SQL Server Errors series, the exact messages and what actually causes them. The errorMsg 916  ·  Level 14  ·  State 2 The server principal “ErrDemo916” is not able to access the database “DemoDatabase” under the current security context. Msg 916, Level 14, State 2 ⚡Check the database, not the login: the named…

    Read More


  • Login Failed: The Account Is Disabled (Error 18470)

    🚨Part of the SQL Server Errors series, the exact messages and what actually causes them. The errorMsg 18470  ·  Level 14  ·  State 1 Login failed for user ‘ErrDemoDisabled’. Reason: The account is disabled. Msg 18470, Level 14, State 1 ⚡Enable is one line; the real question is why it was off. sys.server_principals modify_date tells…

    Read More