0
我有一個問題,我沒有得到任何錯誤,儘管沒有錯誤!我有這一切工作,然後突然它停止工作。除此之外,我的其他所有SQL工具都可以在我的腳本上運行:SQL INSERT沒有錯誤
// Submit the form and enter the details into the database
$result = $dbc->prepare('INSERT INTO users (user_name, pwd, date, user_level) values(?,?,?,?)');
$result->bind_param('sssi', $username, $hash, $now, $userlevel);
printf("Errormessage: %s\n", $result->error);
$result->execute();
$result->close();
它不會返回任何錯誤。它非常奇怪。沒有任何內容插入到數據庫中。
嘗試在'execute'之後輸出錯誤。有一點突出的是'日期'是一個保留字 –