Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
A SQL challenge
Message
De
10/04/2014 14:58:02
 
 
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Titre:
Versions des environnements
SQL Server:
SQL Server 2005
Application:
Web
Divers
Thread ID:
01598405
Message ID:
01598460
Vues:
41
>
>I think CROSS APPLY and the Subquery shown by Walter are actually equivalent. I prefer CROSS APPLY as we can have more than 1 column.
>
>Brad Schulz had a blog explaining that CROSS APPLY and subquery is the same.

I personally like CROSS APPLY, but I have to acknowledge it can be a little more costly on IO/TIME statistics and the execution plan.

What is kind of amazing is how much Microsoft has optimized correlated subqueries over time. As recently as SQL 2000 (which was used by many deep into the second part of the decade), execution plans for correlated subqueries were often horrible. But by the next release the optimizer did a much better job with them
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform