merging-square

Merging Boundary Points: Does a Changing Partition_Number Indicate Data Movement?

I received a question from a reader a while back who was testing out a partitioning architecture: We are testing table partitioning using one filegroup per partition. When we merge a boundary point, we see that partition_number changes in sys.partitions. Does this mean that data movement is occurring? Short Answer: Just because partition_number is changing does […]

dear-sql-dba-lost-in-performance-troubleshooting

Lost in Performance Troubleshooting – Kendra’s Perf Triage for SQL Server (Dear SQL DBA)

The SQL Server is slow, what should you do? I answer a reader question and share my strategy for performance troubleshooting. Note: This is a “listen-able” video. You can also listen to this as a podcast – learn how at littlekendra.com/dearsqldba. This week, our question is about troubleshooting performance Dear SQL DBA, is there any step-by-step script that […]

test-for-race-conditions-square

Testing an Insert for Race Conditions with Ostress.exe

Whenever we have multiple sessions modifying data, things get tricky. When we have a pattern of “check if the data exists and then do a thing,” multiple sessions get even more complicated. It’s not very practical to try to open a bunch of sessions in SQL Server Management Studio to run commands in a loop. […]

dear-sql-dba-bleeding-in-edgeville

Bleeding In Edgeville – When Upgrades Come Too Fast (Dear SQL DBA)

In this episode of “Dear SQL DBA,” I answer a question about early adoption of SQL Server, discuss why testing in production isn’t necessarily crazy, and recommend how to handle requests to upgrade your SQL Server to use new features. Note: This is a “listen-able” video. You can also listen to this as a podcast – […]

merge-troubles-square

The Case of the Blocking Merge Statement (LCK_M_RS_U locks)

Recently I got a fun question about an “upsert” pattern as a “Dear SQL DBA” question. The question is about TSQL, so it lent itself to being answered in a blog post where I can show repro code and screenshots. Here’s the Scenario in the Anonymized Question We have a lookup table, which is the […]

blogger-easy-free-use-square

Blogger Tip: Easy Free-Use Images with Pablo by Buffer

I’ve gotten a few compliments lately on the images I’ve been using in my posts. Images help engage your readers. You should also set a “featured image” for each post for thumbnail usage in your theme or in RSS readers. But it can be kind of a pain to search for images and make sure the image […]

index-usage-stats-bug-starts-to-disappear

Index Usage Stats Bug Fixed in SQL Server 2012 SP2 CU12 / SP3 CU3

Microsoft has just released a new round of cumulative updates for SQL Server 2012, and the release notes indicate that a fix to the sys.dm_db_index_usage_stats dynamic management view has been included in these updates. This is good news for index tuners using SQL Server 2012. As of SP2 + CU12 and SP3 + CU3, SQL […]

I got to teach in a pod at SQLBits

Sabbatical Update: 4 Months of Fun and Reflection

I’m about four months into my planned six month sabbatical. At the beginning, I worried a little that I might not like life as a grownup without a job. Would I feel lost? Purposeless? Bored? Nope. It turns out that I am excellent at not having a real job. I’ve learned a bunch, enjoyed life, seen […]