Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Speed up SQL
Message
 
 
À
11/06/2013 17:19:23
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Titre:
Versions des environnements
SQL Server:
SQL Server 2008
Application:
Desktop
Divers
Thread ID:
01576055
Message ID:
01576084
Vues:
35
>>Try materialize cte into a temp table. It often helps.
>>
>
>Thanks, I'll try that, although I thought some time ago you had suggested using a CTE to speed up another query.
>
>>Also, make sure to provide aliases for ALL columns in your queries when you use several tables. Your last select statement has columns without aliases, so it's hard to see which table they belong to.
>>
>
>You've mentioned this to me before but the standard in this database is the first three letters of each field indicates what table it's from so that is unnecessary.
>

In some situations materializing CTE into a temp table makes a lot of difference. It may not be necessary in your case, but it's worth to try.
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform