Thank you I worked it out, but when I run a search with 2 or more varibles is there some way to run a wildcat. Meaning if someone doesnt type in a varible in say "city" for the search, then my search doesnt work. I figured out the "=" for exact and "LIKE" for something close. If its blank the search shows nothing, even if there is something for the other varible, for instance "state". Can you do something with "OR" to solve this problem or do I have to make multiple search forms to get around this. Hope this makes sense Thank you beav33 $query_Recordset1 = sprintf("SELECT propertytype, squarefootage, askingprice, `city`, `state`, zip FROM houselisting WHERE `state` = %s AND `city` LIKE CONCAT('%%', %s, '%%')"