Jump to content

[SOLVED] what should i put on auto increment column?


coder9

Recommended Posts

hello

 

i have this code below.

 

$query = "INSERT INTO jwinners (gsid, game_no) VALUES (1,'.$current_game_no.')";

 

I'm a little confused and don't know exactly what value to put on a column that has auto increment (index).

 

notice that gsid is an auto increment column.

 

I wonder what is the right syntax for the INSERTion?

 

i just put the 1 value into gsid column.

 

and it generated an error.

 

since gsid is auto increment column, i don't know what to put.

 

 

Thank you.

 

 

 

 

 

the gsid . The ID column.

 

ACE

 

 

Yes, exactly. that is the ID column.

 

 

 

in saying that you could make either one the auto increment column. But if you wish to insert the game number manually. Then its fine how it is.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.