0

When i try to create table using the below code,

CREATE TABLE `audit` (
  `audit_id` int(10) unsigned NOT NULL auto_increment,
  `order_id` int(11) NOT NULL default '0',
  `datestamp` datetime NOT NULL default '0000-00-00 00:00:00',
  `message` text NOT NULL,
  `message_number` int(11) NOT NULL default '0',
  PRIMARY KEY  (`audit_id`)
) TYPE=MyISAM AUTO_INCREMENT=196 ;

1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'TYPE=MyISAM AUTO_INCREMENT=8'

Can someone help me to rectify the error?

Thanks

2

1 Answer 1

3

yes... use ENGINE instead TYPE like this

CREATE TABLE `category` (
 `category_id` int(10) unsigned NOT NULL auto_increment,
 `department_id` int(10) unsigned NOT NULL default '0',
 `name` varchar(50) NOT NULL default '',
 `description` varchar(200) default NULL,
  PRIMARY KEY  (`category_id`)
) ENGINE=MyISAM
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.