Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

SQL syntax error


Guest

Recommended Posts

Posted

I am migrating an oscommerce website to a new server, and I run into this sql error.

 

#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 `orders_products` (
 `orders_products_id` int(11) NOT NULL auto_' at line 4 

 

Is there anything wrong with this that you can see? My knowledge of MySql isn't current with the bleeding edge version. Here is that section from the sql:

 

/*!40000 ALTER TABLE `orders` ENABLE KEYS */;

--
-- Table structure for table `orders_products`
--

DROP TABLE IF EXISTS `orders_products`;
CREATE TABLE `orders_products` (
 `orders_products_id` int(11) NOT NULL auto_increment,
 `orders_id` int(11) NOT NULL default '0',
 `products_id` int(11) NOT NULL default '0',
 `products_model` varchar(12) default NULL,
 `products_name` varchar(64) NOT NULL default '',
 `products_price` decimal(15,4) NOT NULL default '0.0000',
 `final_price` decimal(15,4) NOT NULL default '0.0000',
 `products_tax` decimal(7,4) NOT NULL default '0.0000',
 `products_quantity` int(2) NOT NULL default '0',
 PRIMARY KEY  (`orders_products_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

 

 

Thanks for reading and for any help you can give!

Posted
I am migrating an oscommerce website to a new server, and I run into this sql error.

 

#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 `orders_products` (
 `orders_products_id` int(11) NOT NULL auto_' at line 4

 

Is there anything wrong with this that you can see?

This is bog standard sql if you ask me. Perhaps the file is too big and it stopped reading at that point? Try splitting up the file in that case?

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...