Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Noobie INSERT syntax error

Status
Not open for further replies.

Floodster

Technical User
Jan 28, 2005
204
Hi Guys,
I've been spending the weekend converting my site from .ASP & Access to .ASP & MySql. I have used the MySql Migration kit for my database & tables but I'm having a few problems.

I have a table which consists of ID, surname & forename. The ID was an autonumber in access & the other 2 columns were text.
I have just tried a simple INSERT query using MySql & I'm getting an error of "Field ID doesn't have a default value"
My syntax was;
Code:
INSERT into tbl_members (forename, surname) VALUE ('any', 'body');

can anybody help??
 
I have fixed this by using changing the column to use 'AUTO_INCREMENT'. Why would the migration tool not have done this for me??
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top