#Temp tables in SP

  • hi All,

    I am facing a typical problem in my SP, actually the SP is using may temp tables.

    For better logic i have removed a temp table (#AggreTemp), when i see the Statistics IO of my SP that temp table(#AggreTemp) is still showing in IO. But the SP Is working fine. i have double checked that the "#AggreTemp" is used in the SP Or not, it is not in the SP.

    i have tried by clearing the Proc Cache FreeProceCache/DropCleanbuffers even it is showing in the Statistics IO.

    Please help me on this.



  • Post the code of the stored procedure. Without it, the best folks can do is guess.

    β€œWrite the query the simplest way. If through testing it becomes clear that the performance is inadequate, consider alternative query forms.” - Gail Shaw

    For fast, accurate and documented assistance in answering your questions, please read this article.
    Understanding and using APPLY, (I) and (II) Paul White
    Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden

  • Actually the SP is calling one more SP, in that sp we have used the same temp table.

    Thank you,


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

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