ONYX
asked on
TEMPDB and TempDev
The TEMPDB Database on our server has been growing at an alarming rate. It gets up to 16 Gig some days before we get a chance to shrink it.
I've been told that complex SQL Queries and Complex Joins will cause TEMPDB to grow. Is this true? And if it is, why is this the case...in other words, what would a SQL Query use TEMPDB for?
We are trying to use SQL Profiler to isolate what is causing TEMPDB to grow...is this the correct approach?
Thanks
I've been told that complex SQL Queries and Complex Joins will cause TEMPDB to grow. Is this true? And if it is, why is this the case...in other words, what would a SQL Query use TEMPDB for?
We are trying to use SQL Profiler to isolate what is causing TEMPDB to grow...is this the correct approach?
Thanks
Yes, this is true. Temp tables, and large sorts will also use TEMPDB.....Using profiler should allow you to capture most statements that hit tempdb....
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
I appreciate the comments and the links. That does help. If we do not use Temp Tables in our application, but we do use large sql queries with complex joins, would temp db still fill up? I did note that tempdb is use for sorts...
Thanks again.
Thanks again.
It's possible--just depends on how large and complex things get. SQL will also use tempdb for other things as well. Sometimes you may not create a temp table, but SQL will in order to speed things up.