我不明白为什么出现Statement :: execute()错误? [英] I don't understand why I've Statement::execute() error?
本文介绍了我不明白为什么出现Statement :: execute()错误?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我的代码有错误,但没有找到我的错误...请您能帮我吗? 这是我的代码:
I've a error in my code but I do not find my error... Can you help me please ? here is my code :
$updt=$connect->prepare("INSERT INTO utilisateurs VALUES ('',:nom, :prenom, :email, :identifiant, MD5(:mdp)");
$updt->execute(array('nom'=>$nom,
'prenom'=>$prenom,
'email'=>$email,
'identifiant'=>$identifiant,
'mdp'=>$motDePasse
));
header('./gestion-utilisateur.php');</pre>
这是错误:
Warning: PDOStatement::execute(): SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 2 in...
预先感谢您的帮助.
推荐答案
可能会帮助您
$updt=$connect->prepare("INSERT INTO utilisateurs VALUES ('',:nom, :prenom, :email, :identifiant, MD5(:mdp))");
// I think u missed one parathesis at the last thats it ^
这篇关于我不明白为什么出现Statement :: execute()错误?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文