Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Removing records from a SQL query
Message
 
 
À
21/01/2010 15:51:39
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Versions des environnements
SQL Server:
SQL Server 2008
Application:
Web
Divers
Thread ID:
01445297
Message ID:
01445308
Vues:
24
>>Try to GROUP BY PrimaryKey, PrimaryKeyChildTable and MIN(ChildTableField) AS ChildTableField
>
>When I add a GROUP BY clause, it takes forever to do the query. This is returns immediately as is. But, with the GROUP BY, it keeps processing. I am trying to figure out why it reacts like that.

Can you post your exact query, the CREATE table structure and what indexes do you have. Also try the row_number() idea, though I think it should perform with the same speed as GROUP BY.
If it's not broken, fix it until it is.


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

Click here to load this message in the networking platform