小编Nin*_*881的帖子

为什么我的MySQL查询失败

我不能让它工作,不断收到错误信息.

错误

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 '-mail, password, 
birth_date, age, sex, profile_text, zip_code, zip_code_state, c' at line 1
Run Code Online (Sandbox Code Playgroud)

mysql_query("INSERT INTO users (username, e-mail, password, birth_date, age, sex,
      profile_text, zip_code, zip_code_state, coins, rank, profile_visits, 
      profile_likes, profile_image, profile_points, activated, deleted, reg_time, 
      last_active_time, reg_ip)
    VALUES ('$randomName', 'awduhawd@hotmail.com', 'awd', '21/05/1990','0','2',
      '0','4306','Sandnes','0','user','0','0','$image','0','0','0','$time',
      '$time','0')")
 or die(mysql_error());
Run Code Online (Sandbox Code Playgroud)

php mysql database

4
推荐指数
1
解决办法
82
查看次数

标签 统计

database ×1

mysql ×1

php ×1