--- In php-list@yahoogroups.com, Brian E Boothe <[EMAIL PROTECTED]> wrote:
>
> argg on my form id is an autoincrement Value  why is it tell me id 
> cannot be null
>  "how can i get it in Automatically ???
>

------

This is generally what I use when making the id in the table:

id_name MEDIUMINT UNSIGNED NOT NULL AUTO_INCREMENT,

And when you are inserting rows, you do NOT type anything about this
id column; it will automatically update it as you insert a row.  For
example, something like this:

mysql_query("INSERT INTO users (name, email, password) VALUES
('$name', '$email', '$password') ")
or die(mysql_error());

This will insert a new row, and even though you don't tell it to
update the id, it automaticaly does.

Hopefully that answers your question.

By the way, you should be staring a new topic for a new question.

-bryan

Reply via email to