Menu

#2 Column count doesn't match value count at row 1

open
nobody
None
5
2008-04-23
2008-04-23
Yudi Rosen
No

When I try to register I get this error: "Column count doesn't match value count at row 1" so I got into the PHP and you're missing a field at the end.

Here's the fixed query (line 20 in register.php):
$query = "INSERT INTO mp3act_users VALUES (NULL,\"".$_POST['register']['new_username']."\",\"".$_POST['register']['firstname']."\",\"".$_POST['register']['lastname']."\", PASSWORD(\"".$_POST['register']['password']."\"),1,NOW(),1,\"".$_POST['register']['email']."\",\"streaming\",0,\"s\",\"$md5\",\"\",\"\",1,\"\",\"\",\"\",0)";

It was missing a /"/" blank field at the end.

Discussion

  • Yudi Rosen

    Yudi Rosen - 2008-04-23

    Logged In: YES
    user_id=1550808
    Originator: YES

    whoops... thats \ not / in my last line...

     
  • Nobody/Anonymous

    Logged In: NO

    booo

     
  • Nobody/Anonymous

    Logged In: NO

    thanks for fixing that. I was having the same problem

     

Log in to post a comment.

MongoDB Logo MongoDB