echo "</br></br></br>" . $sql;
mysql_query($sql) or die("Entry not added to database.");
正在吐痰:
INSERT INTO potentials (id, firstname, lastname, age, email, phone, twitter, timeofday, dayofweek, address, city, state, zip, joindate, parentname, parentnumber) VALUES (null, 'Rick', 'Bross', '14', 'rbross3@gmail.com', '8164896991', '@rick_bross', 'After 5:30PM', 'Weekdays', '1234 Cooper', 'Raymore', 'MO', '64130', '2013-04-09 20:10:06', 'Rick Bross II', '1234123412')Entry not added to database.
为什么不正确插入?我可以检查其中一个字符串是否适合我的数据库列(类型类型字符错误或其他)?
答案 0 :(得分:1)
mysql_query($sql) or die(mysql_error());
尝试msql_error()函数。全局显示您的sql执行发生的每个错误