Forum Moderators: open

Message Too Old, No Replies

mysql syntax error cant figure this out

         

tyler245

3:33 am on Jul 12, 2007 (gmt 0)

10+ Year Member



someone please help i have been trying to import my dump file but says theres a mysql syntax error and i have been trying to figure it out for hours someone please help this is what it says to fix or w/e

SQL query:

--
-- Table structure for table `adv`
--
CREATE TABLE `adv` (

`adv_id` bigint( 20 ) NOT NULL AUTO_INCREMENT ,
`adv_name` varchar( 255 ) NOT NULL default '',
`adv_text` text NOT NULL ,
`adv_status` enum( 'Active', 'Inactive' ) NOT NULL default 'Active',
PRIMARY KEY ( `adv_id` )
) ENGINE = MYISAM DEFAULT CHARSET = latin1 AUTO_INCREMENT =9;

MySQL said:

#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 'DEFAULT CHARSET=latin1 AUTO_INCREMENT=9' at line 7

subikar

4:33 am on Jul 12, 2007 (gmt 0)

10+ Year Member



The sql is correct tyler245, It is not giving error. Try once more....

CREATE TABLE `adv` (
`adv_id` bigint( 20 ) NOT NULL AUTO_INCREMENT ,
`adv_name` varchar( 255 ) NOT NULL default '',
`adv_text` text NOT NULL ,
`adv_status` enum( 'Active', 'Inactive' ) NOT NULL default 'Active',
PRIMARY KEY ( `adv_id` )
) ENGINE = MYISAM DEFAULT CHARSET = latin1 AUTO_INCREMENT =9;

Thanks
Subikar

tyler245

4:39 am on Jul 12, 2007 (gmt 0)

10+ Year Member



ive been trying for hours :(

tyler245

4:40 am on Jul 12, 2007 (gmt 0)

10+ Year Member



and it still didnt work either said same thing :(

tyler245

5:03 am on Jul 12, 2007 (gmt 0)

10+ Year Member



and i noticed my phpmyadmin is 2.9 how do i make it 2.10 someone please help

tyler245

6:02 am on Jul 12, 2007 (gmt 0)

10+ Year Member



and i am getting no help all i wanna do is upgrade phpmyadmin will someone please guide me thru it with a good tut please
thanks

phranque

9:25 am on Jul 12, 2007 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



welcome to WebmasterWorld, tyler245!

when i did a "SHOW CREATE TABLE tablename" in mysql 4.1, there was a very slight difference in syntax - not sure if it makes a practical difference, but worth a try:

CREATE TABLE `adv` (
`adv_id` bigint(20) NOT NULL AUTO_INCREMENT,
`adv_name` varchar(255) NOT NULL default '',
`adv_text` text NOT NULL,
`adv_status` enum( 'Active', 'Inactive' ) NOT NULL default 'Active',
PRIMARY KEY ( `adv_id` )
) ENGINE=MyISAM AUTO_INCREMENT=9 DEFAULT CHARSET=latin1

tyler245

10:30 am on Jul 12, 2007 (gmt 0)

10+ Year Member



eh thanks anyway but didnt help at all same thing...i think all i need to do is upgrade myadminphp but i dont know how can someone help me please?