When uninstalling the product module a typo in the ec_product.install file triggers a bunch of error messages as it tries to create all the product related database tables again.

user warning: Table 'ec_product' already exists query: CREATE TABLE ec_product ( `nid` INT unsigned NOT NULL DEFAULT 0, `vid` INT unsigned NOT NULL DEFAULT 0, `pparent` INT NOT NULL DEFAULT 0, `sku` VARCHAR(75) DEFAULT NULL, `price` DECIMAL(10, 2) NOT NULL DEFAULT 0, `ptype` VARCHAR(75) NOT NULL DEFAULT '', `hide_cart_link` INT unsigned NOT NULL DEFAULT 0, UNIQUE KEY vid (vid), INDEX pparent (pparent), INDEX ptype (ptype) ) /*!40100 DEFAULT CHARACTER SET UTF8 */ in //includes/database.inc on line 515. 
user warning: Table 'ec_product_ptypes' already exists query: CREATE TABLE ec_product_ptypes ( `ptype` VARCHAR(32) NOT NULL, `name` VARCHAR(32) NOT NULL, `description` LONGTEXT NOT NULL, PRIMARY KEY (ptype) ) /*!40100 DEFAULT CHARACTER SET UTF8 */ in /includes/database.inc on line 515. 
user warning: Table 'ec_product_features' already exists query: CREATE TABLE ec_product_features ( `ptype` VARCHAR(32) NOT NULL, `ftype` VARCHAR(32) NOT NULL, `weight` INT NOT NULL, PRIMARY KEY (ptype, ftype) ) /*!40100 DEFAULT CHARACTER SET UTF8 */ in /includes/database.inc on line 515. 

small patch attached which should fix the problem.

For the record, I tested all the other uninstall routines and they all worked as expected.

CommentFileSizeAuthor
ec_product.install.patch677 bytesDublin Drupaller

Comments

gordon’s picture

Status: Needs review » Fixed

Thanks fixed.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.