SQL Server According to Bob

Two guys who work on SQL Server

Category: SQL Server Mysteries

Using SQLBCP Native/Format File vs Text File and the BOM

BCP fundamentals when using format file and UNICODE data.

Read More

SQL Mysteries: Why is my SQL Server experiencing lots of 17830 (TCP 10054) errors?

I was reviewing a test run this week that had more SQL 17830 (TCP 10054 / 0x2746) errors than I could explain from just kills or login timeouts. I started looking at the output in the connectivity ring buffer and the matching XEvent, error_reported event where error_number = 17830. I thought I would find my […]

Read More

SQL Mysteries: Causality tracking vs Event Sequence for XEvent Sessions

You need to make sure to order the events by event_sequence when doing analytics on the XEvent data. It has been proposed to me that you can use the causality tracking sequence as a sort target, which may work as long as you understand how the activity ids are associated with the parent and the […]

Read More

SQL Mysteries: SQL Server Login Timeouts – A Debugging Story

This blog takes you through the debugging journey, refreshing us on old concepts and introducing some new ones. Reported Symptoms ·         Random connection failures from both SQL Authentication and AD based logins ·         Failures occur from remote clients or sqlcmd executed directory on the server (/opt/mssql-tools/bin) ·         Unpredictable when failures occur ·         Non-yielding scheduler reports […]

Read More

SQL MYSTERIES: Tracing BCP Might Fool You

Today I was tracking a large BCP.exe ‘IN’ operation and monitoring the sys.dm_exec_requests entries.  The ‘BULK INSERT’ command entry appeared, showing the CPU, reads, writes, … but these values where getting reset from time to time.  Here are 3 snapshots from my system. cpu_time    total_elapsed_time      writes      session_id   start_time              command 1387        1396                    32          51           2018-08-07 00:45:42.670 […]

Read More

SQL Server Mysteries: The Case of the Dropped AD Group Login

Dylan (who kindly wrote up the contents of this blog for me) was modifying the tests for Active Directory Login activities.  As Dylan and I reviewed the changes a specific behavior involving Active Directory Group Logins caught our attention. Imagine you have a group on your domain [CONTOSO\group] which has a member [CONTOSO\user], and the […]

Read More

SQL Server Mysteries: The Case of the Suspended, Awaiting Command, and Blocked Session

  I ran into a scenario showing my session as suspended, awaiting command and blocked!  My first thought was that this had to a bug. As many of us have documented, for years, a sleeping, awaiting command, session is a session waiting on the client to submit a TSQL command to the SQL Server. The […]

Read More

SQL Server Mysteries: The Case of the Not 100% RESTORE…

I recently visited a customer onsite and presented to them topics on SQL Server 2016. After the talk, I opened up the floor for the audience to ask me questions. One question I got went like this “I’ve tried to restore a database on SQL Server using the WITH STATS option. When I run the […]

Read More