I am attempting to create a keyword search that will pull from my database. From what I understand I want to use the like statement. This is what I was trying to do...
$query = "SELECT jobTitle FROM $tableName LIKE '%$searchVar%'";
$result = mysql_query($query, $conn);
while ($row = mysql_fetch_array($result))
{
echo $row['jobTitle'];
echo "<br>";
}
I am not sure if this is the correct way to write the query using the like statement, I am currently researching this but if anyone can help I would appreciate it greatly. Thanks for your time.