Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Table variables in sql

Author  Topic 

Nitu
Yak Posting Veteran

81 Posts

Posted - 2006-06-14 : 10:09:30
Hi,

I have a question on table variables. I read some articles where they compared table variables with temporary tables. There they say that when data set is small you can use table variables, but when data set is large its best to use temp tables.

My question is when they say large data set, in terms of no. of records, what would be the no. of records (approx..) that would define the data set as a large set which makes it use the temp tables.

Like data with records >1000 or >10000 or >100000 !!! (say for example)

Can somebody help me with this.

Thanks a lot in advance,
Nitu

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2006-06-14 : 10:14:24
http://www.aspfaq.com/show.asp?id=2475
http://support.microsoft.com/default.aspx?scid=kb;en-us;305977

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

RyanRandall
Master Smack Fu Yak Hacker

1074 Posts

Posted - 2006-06-14 : 10:31:53
Nitu - I'm afraid you won't get a definitive answer to your question. The only way to know for sure which is faster for a particular situation is to try them both in your environment.

Ryan Randall
www.monsoonmalabar.com London-based IT consultancy

Solutions are easy. Understanding the problem, now, that's the hard part.
Go to Top of Page

Nitu
Yak Posting Veteran

81 Posts

Posted - 2006-06-14 : 10:41:34
Thanks for the articles.
Go to Top of Page
   

- Advertisement -