SQL Server 2012 Row Selection

I need to select rows without Blender in the name. I have used the not like operator but it seems not to be working.
Screenshot--883-.png
Rob FriedAsked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
Pawan KumarConnect With a Mentor Database ExpertCommented:
try
SELECT SerialNo,Name,Cost
FROM Equipment
WHERE Cost < 2000 AND name NOT LIKE '%blender%'

Open in new window

0
 
Jim HornConnect With a Mentor Microsoft SQL Server Developer, Architect, and AuthorCommented:
^^^  Your T-SQL NOT LIKE was missing the wildcard characters % that are present in the above query.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.