<?php
$conn = new mysqli("localhost", "root", "", "hcis") or die(mysqli_error());
$conn->query("DELETE FROM `itr` NATURAL JOIN `vaccine` WHERE `itr_no` = '$_GET[id]'") or die(mysqli_error());
header("location:patient.php");
?>
这是我的示例代码。我打算删除两个相关表中的数据,当我运行它时,我收到此错误:
警告:mysqli_error()期望在第3行的C:\ xampp \ htdocs \ thesis \ admin \ delete_patient.php中给出1个参数0
请帮助..我认为我的查询不正确。