also keep in mind temp tables (@ / # / ## ) are hosted in tempdb. tempdb is used at (sqlserver) instance level, for more than only storing temp tables. (sorting, grouping, ..)
Actually, Temp Tables and Table Variables start out in memory... if they fit, that's as far as they go. If they don't, then they spill into the physical disk.
But, don't take anyone's word for that... instead of sifting through the manure to figure out what the horse was thinking, ask the horse.
Please read the following Microsoft FAQ...http://support.microsoft.com/default.aspx?scid=kb;en-us;305977&Product=sql2k
is pronounced ree-bar and is a Modenism for R
First step towards the paradigm shift of writing Set Based code: Stop thinking about what you want to do to a row... think, instead, of what you want to do to a column.
Although they tell us that they want it real bad, our primary goal is to ensure that we dont actually give it to them that way.
Although change is inevitable, change for the better is not.
Just because you can do something in PowerShell, doesnt mean you should. Helpful Links:
How to post code problemsHow to post performance problemsForum FAQs