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!

Grief Creating Table 1

Status
Not open for further replies.

TamedTech

IS-IT--Management
May 3, 2005
998
GB
Hi Guys,

I feel stupid for asking this question but never mind.

I'm using phpMyAdmin to administer my database, and i'm trying to create a simple table to hold a product list in it, but every time i attempt it i get the following error kicked back at me.

Code:
Error 
SQL-query: 

CREATE TABLE products_list (product_id TINYINT  not null AUTO_INCREMENT, product_name TEXT  not null , case SMALLINT  not null , size SMALLINT  not null , level SMALLINT  not null , cost SMALLINT  not null  , PRIMARY KEY (product_id))
MySQL said: You have an error in your SQL syntax near 'case SMALLINT not null , size SMALLINT not null , level SMALLINT not null , c' at line 1

I cant see what i'm doing wrong.

Thanks,

Rob
 
CASE is a reserved word in MySQK - see:

________________________________________________________________
If you want to get the best response to a question, please check out FAQ222-2244 first.
'If we're supposed to work in Hex, why have we only got A fingers?'
Drive a Steam Roller
 
Ah i see ... wasnt such a silly question after all then.

Thanks for that buddy it worked a charm.

Rob
 
You're welcome, and thanks for the LPS!

________________________________________________________________
If you want to get the best response to a question, please check out FAQ222-2244 first.
'If we're supposed to work in Hex, why have we only got A fingers?'
Drive a Steam Roller
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top