How to See Rowcounts and Execution Time for In-Flight Queries in SQL Server
I frequently need to see rowcounts and execution time for queries while they’re running. Maybe I’m troubleshooting a slow query β¦
Read MoreBy Kendra Little on β’ 4 min read
No matter what I write in this post, some of y’all are going to tell me I’m wrong. That’s inevitable, because I’m writing about tempdb: a database so complex and mysterious in SQL Server, that even the spelling and capitalization of the database name is a topic of great disagreement.
You might think, “This is easy, just check Microsoft’s documentation to find the answer.”
That’s a great idea, except you’ll find multiple variations of “tempdb” on Microsoft.com:
So the good news is, if you’re writing for casual usage, there are a lot of different alternate spellings out there, and that’s OK. Most people do NOT use a space and make “Temp DB” two words, but you’ll see variations of that around the internet as well.
However, it can be nice to have a sense of the “most accepted” current spelling and capitalization of a term. This is especially useful if you’re building a tool with a GUI and you want it to look as “standard” as possible, or if you’re writing for a company website.
Here’s my take on what’s won the contentious “tempdb” spelling and capitalization wars.
A few years back, I believe I saw Paul Randal point out on Twitter that tempdb is a real database, and the database is spelled tempdb. This simple argument has persuaded quite a few of us who write in the SQL Server world that there’s no use for any spaces in there, and that the “db” bit shouldn’t be capitalized. (Time has passed and I can’t find the tweet, so hopefully I’m attributing this correctly.)

You will find some variation in capitalization of tempdb on the SQL Skills blog, but Paul tends to use lowercase “tempdb” even at the beginning of a bullet point.
My colleague Kathi Kellenberger is the editor of Simple Talk. On posts she edits, she uses lower case tempdb, but there are exceptions as in when tempdb is the first word in an article title. (This is a good article to look at as a style guide, in my opinion.)
I have also noticed that other frequent writers in the Microsoft Data Platform space have standardized on “tempdb” somewhat, so if you choose this you are in good company:
I try to be consistent using “tempdb” on this site, and I mostly succeed at this lately. I tend to be massively inconsistent about title casing in general, but I do my best. (Truth: I didn’t even capitalize the title of this post like I usually do, I had to go back and edit it after publishing, haha.)
My colleague Piers is on the SQL Monitor team at Redgate. The team was chatting about how tempdb is so complicated that it’s not even obvious how to spell or capitalize it, and he said, “you know, maybe someone should write a blog post.” π‘
And there’s always room for one more post about tempdb, right?
Copyright (c) 2025, Catalyze SQL, LLC; all rights reserved. Opinions expressed on this site are solely those of Kendra Little of Catalyze SQL, LLC. Content policy: Short excerpts of blog posts (3 sentences) may be republished, but longer excerpts and artwork cannot be shared without explicit permission.