...

View Full Version : Query Error when creating a table



whizard
09-23-2006, 12:33 AM
Hello all

I am getting an error when I try to run a query on my site. I can't seem to figure out what's wrong with it, and I thought some of you might know.

Here's the error:

Could not complete because: 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 'DEFAULT CHARSET=latin1 AUTO_INCREMENT=18 ; INSERT INTO `users`

Here's the Query


CREATE TABLE `users` (
`id` tinyint(10) NOT NULL auto_increment,
`permission` tinyint(1) NOT NULL default '0',
`username` varchar(20) NOT NULL default '',
`password` text NOT NULL,
`email` varchar(100) NOT NULL default '',
PRIMARY KEY (`id`),
UNIQUE KEY `username` (`username`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=18 ;

INSERT INTO `users` VALUES (-, --, '---', '----', '-----');
INSERT INTO `users` VALUES (-, --, '---', '----', '-----');
INSERT INTO `users` VALUES (-, --, '---', '----', '-----');
INSERT INTO `users` VALUES (-, --, '---', '----', '-----');
INSERT INTO `users` VALUES (-, --, '---', '----', '-----');
INSERT INTO `users` VALUES (-, --, '---', '----', '-----');
INSERT INTO `users` VALUES (-, --, '---', '----', '-----');
INSERT INTO `users` VALUES (-, --, '---', '----', '-----');
INSERT INTO `users` VALUES (-, --, '---', '----', '-----');
INSERT INTO `users` VALUES (-, --, '---', '----', '-----');


(I removed the information I am inserting, since that's not where the error is...)

Thanks in Advance!

Dan

guelphdad
09-23-2006, 03:05 AM
try removing the charset information.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum