<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>TempDB:: Table variable vs local temporary table</title><link>http://blogs.msdn.com/sqlserverstorageengine/archive/2008/03/30/sql-server-table-variable-vs-local-temporary-table.aspx</link><description>As you know the tempdb is used by user applications and SQL Server alike to store transient results needed to process the workload. The objects created by users and user applications are called ‘user objects’ while the objects created by SQL Server engine</description><dc:language>en</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>dmv</title><link>http://blogs.msdn.com/sqlserverstorageengine/archive/2008/03/30/sql-server-table-variable-vs-local-temporary-table.aspx#8345897</link><pubDate>Mon, 31 Mar 2008 19:55:46 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8345897</guid><dc:creator>dmv</dc:creator><description>&lt;p&gt;PingBack from &lt;a rel="nofollow" target="_new" href="http://manuelsite.freehostingz.com/dmv.html"&gt;http://manuelsite.freehostingz.com/dmv.html&lt;/a&gt;&lt;/p&gt;
</description></item><item><title>re: TempDB:: Table variable vs local temporary table</title><link>http://blogs.msdn.com/sqlserverstorageengine/archive/2008/03/30/sql-server-table-variable-vs-local-temporary-table.aspx#8346177</link><pubDate>Mon, 31 Mar 2008 22:07:15 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8346177</guid><dc:creator>bertcord</dc:creator><description>&lt;p&gt;Good article and sample scripts…a few additional points..&lt;/p&gt;
&lt;p&gt;1.	 Queries using table variables don’t generate parallel query plans. &amp;nbsp;We have found with large temporary datasets it is better to use #tables to take advantage of parallel plans.&lt;/p&gt;
&lt;p&gt;2.	If you need indexes on a @ table you can work around this by defining CONSTRAINTS on Columns. &amp;nbsp;Since under the covers a CONSTRAINT is enforced with indexes this will work. &amp;nbsp;This is required if you need to make updates over linked servers since in 2005 SQL will issues a remote scan across the linked server if columns in JOIN are not indexed.&lt;/p&gt;
&lt;p&gt;Bert&lt;/p&gt;
</description></item><item><title>re: TempDB:: Table variable vs local temporary table</title><link>http://blogs.msdn.com/sqlserverstorageengine/archive/2008/03/30/sql-server-table-variable-vs-local-temporary-table.aspx#8346628</link><pubDate>Tue, 01 Apr 2008 00:46:05 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8346628</guid><dc:creator>Sunil Agarwal</dc:creator><description>&lt;p&gt;thanks. I will update the blog with the additional info you have provided.&lt;/p&gt;
</description></item><item><title>Table Variable vs Parallelism</title><link>http://blogs.msdn.com/sqlserverstorageengine/archive/2008/03/30/sql-server-table-variable-vs-local-temporary-table.aspx#8397702</link><pubDate>Tue, 15 Apr 2008 18:00:50 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8397702</guid><dc:creator>EXEC dbo.LongTermMemory__Archive</dc:creator><description>&lt;p&gt;There are many myths surrounding table variables and one of the most common is probably the 'in memory'&lt;/p&gt;
</description></item><item><title>re: TempDB:: Table variable vs local temporary table</title><link>http://blogs.msdn.com/sqlserverstorageengine/archive/2008/03/30/sql-server-table-variable-vs-local-temporary-table.aspx#8442896</link><pubDate>Wed, 30 Apr 2008 14:08:24 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8442896</guid><dc:creator>colin leversuch-roberts</dc:creator><description>&lt;p&gt;A nice post - I've needed something &amp;quot;microsoft&amp;quot; to point to when I try to explain exactly the points in this post and developers don't believe me &amp;lt; grin &amp;gt;&lt;/p&gt;
</description></item><item><title>re: TempDB:: Table variable vs local temporary table</title><link>http://blogs.msdn.com/sqlserverstorageengine/archive/2008/03/30/sql-server-table-variable-vs-local-temporary-table.aspx#8531867</link><pubDate>Thu, 22 May 2008 17:58:15 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8531867</guid><dc:creator>cf_joe</dc:creator><description>&lt;p&gt;Exactly what I was looking for in understanding the Difference between #table and table variable - Thank You&lt;/p&gt;
</description></item><item><title>re: TempDB:: Table variable vs local temporary table</title><link>http://blogs.msdn.com/sqlserverstorageengine/archive/2008/03/30/sql-server-table-variable-vs-local-temporary-table.aspx#9227263</link><pubDate>Tue, 16 Dec 2008 21:25:17 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9227263</guid><dc:creator>YingGuo</dc:creator><description>&lt;p&gt;Sunil, I have a question about the 'fourth - the operations done on table variable are not logged' part. &amp;nbsp;It is true that a name like '%tv_target%' is not showing in the log, but when I looked at all the log records generated after the insert and update operation on table variable, I saw log entries on AllocationUnitName #2F650636, which is the internal name for @tv_target. Just to confirm it, I checked sys catalogs, also compared these entries with logs generated after the same operations on temp tables, and I am convinced they are the logs on table variables. I did this on SQL 2008. Thanks.&lt;/p&gt;
</description></item><item><title>TempDB Basics (cont..)</title><link>http://blogs.msdn.com/sqlserverstorageengine/archive/2008/03/30/sql-server-table-variable-vs-local-temporary-table.aspx#9245991</link><pubDate>Mon, 22 Dec 2008 03:22:20 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9245991</guid><dc:creator>SQL Server Storage Engine</dc:creator><description>&lt;p&gt;In the previous blog &lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/sqlserverstorageengine/archive/2008/12/21/tempdb-basics.aspx"&gt;http://blogs.msdn.com/sqlserverstorageengine/archive/2008/12/21/tempdb-basics.aspx&lt;/a&gt;&lt;/p&gt;
</description></item></channel></rss>