What type of field is "keyskills"?
What is the actual value of $search1 when you get to that point? (Not what you think it should be, but determine via debugging what it definitely is.)
If it's a text value, (which you are indicating by having quoted it), have you properly escaped any special characters with the applicable function for whichever database extension you are using?