Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 

Wildcards in WHERE Clauses

This is just a very short post regarding the use of wildcards in a WHERE Clause

It is possible that the first WHERE clause below can use an Index seek

Where LastName like ‘[a-z]%ent’ can use an index

This second statement will not be able to use a seek and will result in a scan

WHERE LastName like ‘%ent’

Comments

No comments.

Leave a Comment

Please register or log in to leave a comment.