Tuesday, February 2, 2010

Temporary table VS Table variable: Cursor alternative

Temporary table

This can improve processing speed but consume disk space.
Table variable 

Table variable that can be used in stored procedures, functions and batches. 
Table variable get destroyed at the end of the stored procedure, function or batch in which it is defined. 
Since it can be used in stored procedure, it is compiled once and can be used many times

0 Comments: