562 attributed reviews in the last 3 years
Refreshingly small course sizes
Outstandingly good courseware
Whizzy online classrooms
Wise Owls only (no freelancers)
Almost no cancellations
We have genuine integrity
We invoice after training
Review 30+ years of Wise Owl
View our top 100 clients
Speed comparison of temporary tables against table variables
Part one of a five-part series of blogs
When you are programming in SQL, you often have the choice of using table variables or temporary tables. This blog considers whether one method is substantially quicker than the other (spoiler alert: not really).
This blog assumes that you already know what temporary tables and table variables are (if you don't, you could do worse than read our blogs (here or here) or watch our video tutorials (here or here) on the subject - or go on our advanced SQL course).
Here are the contents of the rest of this blog:
The example used
Explaining the methodology behind this speed comparison
The SQL code to generate and test a temporary table
The same code to generate and test a table variable
The conclusion of the tests, giving relative speeds
I'm running the tests in SQL Server 2016 under Windows 10 Professional, using this laptop:
The configuration of the laptop running these tests.
Let's start with the example I've used, which you can recreate in your own instance of SQL Server.
|Parts of this blog|
25 Aytoun Street