Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
WHERE IN approach
Message
De
28/02/2017 14:07:06
 
 
À
28/02/2017 13:26:17
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Versions des environnements
SQL Server:
SQL Server 2014
OS:
Windows 8.1
Network:
Windows Server 2012
Divers
Thread ID:
01648591
Message ID:
01648633
Vues:
24
>>I realize that the original probably was ONLY example data. But the very first thought (guessing that NoProvince is intX typed) for optimization would be "Between" or the equivalent ">= and <=" query syntax to skip the problem Fabio mentioned ;-)
>
>Yes, we are talking about field of type integer.

So I am pretty certain that for contiuos ranges "Between" or the equivalent >= and <= in where clause should be faster, as only the range of the index needs to be checked, or to say it in Fabios words in this special case "and" can be used instead of "or"
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform