Answer the question
In order to leave comments, you need to log in
Does not retrieve data from the database. Where did I make a mistake in the request?
$dbh = new PDO('mysql:host=localhost;dbname=course_db; charset = utf8', 'root', '');
$sql = 'SELECT * FROM orders, orderdetails WHERE customerNumber="141" AND requiredDate < 2003-07-19 ';
$request = $dbh->query($sql);
foreach ($request as $p) {
echo 'customerName: ' . $p['customerNumber'] . '</br>' . 'requiredDate: ' . $p['requiredDate'] . '</br>' . '<hr>';
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question