LightningSt Posted July 11, 2008 Share Posted July 11, 2008 In PHP myadmin I am trying to actually insert the information in using the code that it creates when you do it by clicking on create table... this is what I have and it sin't working... I was wondering whats wrong? The Error I get is #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 'CREATE TABLE `locations`.`locations` ( `ID` INT NOT NULL AUTO_INCREMENT COMMENT' at line 7 CREATE TABLE `clients`.`clients` ( `ID` INT NOT NULL AUTO_INCREMENT COMMENT 'Identifier', `Name` TEXT NOT NULL COMMENT 'Client Name' , PRIMARY KEY ( `ID` ) ) ENGINE = MYISAM COMMENT = 'Table of Client Names' CREATE TABLE `locations`.`locations` ( `ID` INT NOT NULL AUTO_INCREMENT COMMENT 'Identifier', `Cloc` TEXT NOT NULL COMMENT 'Location Name' , `Ccon` TEXT NOT NULL COMMENT 'Contact Name' , `Cphn` TEXT NOT NULL COMMENT 'Phone Number' , `Cadr` TEXT NOT NULL COMMENT 'Address' , `Czip` TEXT NOT NULL COMMENT 'Zip Code' , `Cstt` TEXT NOT NULL COMMENT 'State' , `Ccit` TEXT NOT NULL COMMENT 'City' , `ClID` INT NOT NULL COMMENT 'Client Name Association' , PRIMARY KEY ( `ID` ) } ENGINE = MYISAM COMMENT = 'Table of Locations' Quote Link to comment Share on other sites More sharing options...
fenway Posted July 11, 2008 Share Posted July 11, 2008 Missing a semi-colon to end the statement after the first create table. Quote Link to comment Share on other sites More sharing options...
willyamPax Posted July 16, 2008 Share Posted July 16, 2008 here i deleted the .clients and .loactions and then i change the { to ) thats all and i tested it to my phpmyadmin and its working now CREATE TABLE `clients` ( `ID` INT NOT NULL AUTO_INCREMENT COMMENT 'Identifier', `Name` TEXT NOT NULL COMMENT 'Client Name' , PRIMARY KEY ( `ID` ) ) ENGINE = MYISAM COMMENT = 'Table of Client Names';# MySQL returned an empty result set (i.e. zero rows). CREATE TABLE `locations` ( `ID` INT NOT NULL AUTO_INCREMENT COMMENT 'Identifier', `Cloc` TEXT NOT NULL COMMENT 'Location Name' , `Ccon` TEXT NOT NULL COMMENT 'Contact Name' , `Cphn` TEXT NOT NULL COMMENT 'Phone Number' , `Cadr` TEXT NOT NULL COMMENT 'Address' , `Czip` TEXT NOT NULL COMMENT 'Zip Code' , `Cstt` TEXT NOT NULL COMMENT 'State' , `Ccit` TEXT NOT NULL COMMENT 'City' , `ClID` INT NOT NULL COMMENT 'Client Name Association' , PRIMARY KEY ( `ID` ) ) ENGINE = MYISAM COMMENT = 'Table of Locations';# MySQL returned an empty result set (i.e. zero rows). Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.