Using profiler on tempdb

  • Hi all,

    We are experiencing problems with our tempdb db so we tried to run the profiler on it to see what is happenning. However it seems the profiler doesn't take into account calls to the tempdb that are done by other db's. Here is a quote that explains what I am saying:

    "if an object on tempdb was created from a user database we will see nothing. We can see activity on tempdb only when on application side something like [use tempdb] was run before the query.

    For example when you create a table on tempdb called ##abc and then query this table using select statement without executing explicity [use tempdb] the usage will only appear under default database."

    Does any of you know anything about this? Is this really true and if yes how can we analyse the access to tempdb considering we have about 6 db's using it... ?

    Thanks

  • This was removed by the editor as SPAM

  • if you add the object event class

    to the trace,

    you can see creation and deletion of tables in tmpdb.

    without executing [use tempdb]  

    hope that helps

  • thanks a lot noam, i discovered that yesterday. after looking at the trace i realised that having over a 1000 sp's creating temp tables with names such as #tmp or #t is a very bad idea

    Anyway, thanks for replying

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply