0
My problem is to leave the first INSERT field empty,(if I fill the program runs), in my phpmyadmin the ID field is AUTO_INCREMENT, but without modifying that part of the code, it stopped.
Code:
$sql = "INSERT INTO usuarios VALUES ('','$user','$sobrenome','$sexo','$nascimento','$senha','$email','$foto','$status')";
$busca = mysqli_query($link,$sql);
$afetado = mysqli_affected_rows($link);
$search = mysqli_query($link,$sql);
– user63045
Here is the error, is returning false.
– user63045
@Gabrielcordeiro you changed the code to be the columns you want to enter and the corresponding values? I did not understand your comment.
– leofontes
ignore my good kkk comment I did what you recommended and also needed to add "null" in the ID value. OBG
– user63045
I have no way to test now, but try to insert "skipping" the ID column in both the column list and VALUES, I think it should work. But I’m glad he helped you ;)
– leofontes