[Solved] Where do I find the meaning of TdsInputBufferError numbers?

EverSQL Database Performance Knowledge Base

Where do I find the meaning of TdsInputBufferError numbers?

Database type:

We are having some sporadic connection errors on some of our SQL servers. I did some searching and found out about the Ring Buffer in SQL 2008 R2 and found some information, but I am not entirely sure how to figure it out.

Running the query

FROM    sys.dm_os_ring_buffers

Gives me some results, on of which is interesting

<Record id="4" type="RING_BUFFER_CONNECTIVITY" time="461419385">
    <RemoteHost>&lt;local machine&gt;</RemoteHost>
    <LocalHost />
    <RecordTime>5/19/2012 16:29:23.831</RecordTime>

So, my question is, where do I find the meaning for the TDS error numbers. In this case <TdsInputBufferError>109</TdsInputBufferError>

How to optimize this SQL query?

The following recommendations will help you in your SQL tuning process.
You'll find 3 sections below:

  1. Description of the steps you can take to speed up the query.
  2. The optimal indexes for this query, which you can copy and create in your database.
  3. An automatically re-written query you can copy and execute in your database.
The optimization process and recommendations:
  1. Create Optimal Indexes (modified query below): The recommended indexes are an integral part of this optimization effort and should be created before testing the execution duration of the optimized query.
Optimal indexes for this query:
CREATE INDEX dm_ring_idx_ring_type ON sys.dm_os_ring_buffers (ring_buffer_type);
The optimized query:
        CAST(sys.dm_os_ring_buffers.record AS XML) 
        sys.dm_os_ring_buffers.ring_buffer_type = 'RING_BUFFER_CONNECTIVITY'

Related Articles

* original question posted on StackOverflow here.