kerry posted 4 years ago in General
my table is not null autoincrement
in heidisql what if i do the query to
load my table.. can i right click and add a row
and edit it. i did that but it ends up ass null
if this kind of editing can be done how do i
make the new row autoincrement not null like
the rest of the table
TTSneko posted 4 years ago
It does not end up as NULL: as soon as you have entered the data in the other fields and pressed RETURN, the "(NULL)" displayed in the ID field is automatically set to the next number.

kerry posted 4 years ago
I don't believe it
I forgot to press enter
but still. does editing and inserting into that way have the
same code value as the code. does it do the same thing without modifying the table properties after editing it by inserting a row and writeing into it.

TTSneko posted 4 years ago
All table row additions done "manually" are treated the same way as with a queried INSERT as the resulting MySQL syntax is the same.

A field declared AUTO_INCREMENT and NOT_NULL therefore automatically receives the next increment and does not stay 'NULL'. Your changes (manual or not) do not influence the way your ID is defined or handled.

Please login to leave a reply, or register at first.