How do you grow all files in a file group equally? The answer is Trace Flag 1117, plus the AutoGrow option that SQL Server 2016 brought for filegroups.
Find the Query Growing TempDB in SQL Server
To find the query growing TempDB, read the space each session has allocated and join it to its statement. This post separates temporary tables from spills, watches both live in a second window and shows the totals after a query ends. It ends with ways to fix a spill.
Temporary Stored Procedures in SQL Server: Local and Global
Temporary stored procedures start with one # sign for a local one and two for a global one, and both live in tempdb. This post creates each kind on a demo database, shows who can call them and when they disappear, and explains which database their object names resolve in. It ends with the habit that makes them useful for testing a rewrite.
How to Shrink TempDB Without SQL Server Restart? – Interview Question of the Week #163
A client ran the shrink command again and again, but TempDB would not get any smaller. Here is how to Shrink TempDB without a SQL Server restart.
Sort in TempDB for Faster Index Rebuilds: When It Helps
To sort in tempdb during an index rebuild, add WITH (SORT_IN_TEMPDB = ON) to ALTER INDEX. This post tests the option and shows that the user database log stays the same size, because only the sort workspace moves. It also explains when the option helps, how much tempdb space it needs, and when to leave it off.
What is WorkTable in SQL Server? – Interview Question of the Week #146
What is a WorkTable in SQL Server? Run a simple CROSS JOIN with STATISTICS IO on and you will see one. Here is what it is and why SQL Server creates it.







