我有问题,我真的需要帮助解决我的问题。我可以更新我的一些记录,但有一些记录,我无法更新。我已经在寻找解决方案,但运气不好。我没有解决我的问题。所以这是我的代码
$lanm = $_POST['lastname'];
$finm = $_POST['firstname'];
$scho = $_POST['school'];
$allo = $_POST['allowance'];
$bday = $_POST['birthday'];
$grad = $_POST['gradelevel'];
$fmly = $_POST['family'];
$favo = $_POST['favoriteSubject'];
$stat = $_POST['status'];
$gnd = $_POST['gender'];
$connection = mysql_connect('localhost', 'root') or die ('Unable to Connect');
mysql_select_db('bighoop') or die ('Unable to Select a database');
$query1 = "UPDATE `tbl_students` SET Gender = '$gnd', `Lastname`='$lanm', `Firstname`='$finm',
`Birthday`='$bday', `Grade_level`='$grad', `Family_size`='$fmly',
`Fav_subject`='$favo', tbl_students.School_id='$scho', tbl_students.Status ='$stat',
tbl_students.Allowance_Id = '$allo' WHERE tbl_students.Student_id ='".$sid[$x]."';";
答案 0 :(得分:0)
具体说明未更新的行和正在更新的行。然后我们才能确定问题