Jeff Moden (1/9/2013)
Alan.B (1/9/2013)
AndrewSQLDBA (1/9/2013)
Its worth noting that the following is sargable.LIKE '%abc%'
Did you mean "NOT" SARGable because it sure doesn't look SARGable from here. 😉 And, I agree... nice use of NTILE.
Thank you very much Jeff. One year ago I had never heard of windows functions, set-based SQL, or a tally table. I think I'm starting to get it and hope to someday be able to write queries like you, Dwain, Lynn and others on SSC.
Yes - I meant NOT SARGable.
-- Itzik Ben-Gan 2001