I give up. I have been reading tons of webpages and cannot figure out why this is not returning any results. I know the data is there, punctuation is correct for the query, the connection works, etc. There are no errors, just no data. Pls help....
Code:
$pdo = new PDO("mysql:host=$hostname; dbname=$database;" , $username, $password);
$dept = "Jeans";
$emp = $pdo->prepare("Select * From Employees Where department = " . $dept);
$emps = $emp->execute();
foreach ($emps as $row) {
echo $row['fname'] . ' ' . $row['lname'] . '<br>';
}