Hello all.
I am a student and started my studies of e-commerce now. I chose a nominee oscommerce and have realized it is a very versatile platform and have a very active forum.
I began my studies by osCommerce Online Merchant v2.2 Release Candidate 2a by me seem more stable.
Installed it on my server and started studying. I found the Add-Ons, I thought fantastic and started installing some of my interest. So far so good, my problems started when trying to install "TotalB2B_1.4a_1", so I ask for help.
When configuring the "TotalB2B_1.4a_1" in a fresh install of OsCommerce v2.2RC2a, I came across the following error when importing the SQL statements to the database:
import:
error:
The SQL code is as follows:
ALTER TABLE customers ADD customers_discount DECIMAL(8,2) DEFAULT '-0' NOT NULL;
DROP TABLE IF EXISTS customers_groups;
CREATE TABLE customers_groups (
customers_groups_id INT(11) NOT NULL AUTO_INCREMENT,
customers_groups_name VARCHAR(32) NOT NULL DEFAULT '',
customers_groups_discount DECIMAL(8,2) NOT NULL DEFAULT '-0',
customers_groups_price INT(11) NOT NULL DEFAULT '1',
PRIMARY KEY (customers_groups_id)
) TYPE=MyISAM;
INSERT INTO customers_groups VALUES (1, 'Default', '-0.00', '1');
INSERT INTO customers_groups VALUES (2, 'WholeSale', '-20.00', '1');
ALTER TABLE customers ADD customers_groups_id INT( 11 ) DEFAULT '1' NOT NULL;
ALTER TABLE customers ADD customers_status int(1) NOT NULL default '0';
ALTER TABLE specials ADD customers_groups_id INT( 11 ) DEFAULT '0' NOT NULL;
ALTER TABLE specials ADD customers_id INT( 11 ) DEFAULT '0' NOT NULL;
DROP TABLE IF EXISTS manudiscount;
CREATE TABLE manudiscount (
manudiscount_id INT(11) NOT NULL AUTO_INCREMENT,
manudiscount_name VARCHAR(128) NOT NULL DEFAULT '',
manudiscount_groups_id INT(11) NOT NULL DEFAULT '0',
manudiscount_customers_id INT(11) NOT NULL DEFAULT '0',
manudiscount_manufacturers_id INT(11) NOT NULL DEFAULT '0',
manudiscount_discount DECIMAL(8,2) NOT NULL DEFAULT '-0',
PRIMARY KEY (manudiscount_id)
) TYPE=MyISAM;
DROP TABLE IF EXISTS catemanudiscount;
CREATE TABLE IF NOT EXISTS catemanudiscount (
catemanudiscount_id INT(11) NOT NULL AUTO_INCREMENT,
catemanudiscount_name VARCHAR(128) NOT NULL default '',
catemanudiscount_groups_id INT(11) NOT NULL default '0',
catemanudiscount_customers_id INT(11) NOT NULL default '0',
catemanudiscount_categories_id INT(11) NOT NULL default '0',
catemanudiscount_manufacturers_id INT(11) NOT NULL default '0',
catemanudiscount_discount DECIMAL(8,2) NOT NULL default '-0',
PRIMARY KEY (catemanudiscount_id)
) TYPE=MyISAM;
DROP TABLE IF EXISTS catediscount;
CREATE TABLE IF NOT EXISTS catediscount (
catediscount_id INT(11) NOT NULL AUTO_INCREMENT,
catediscount_name VARCHAR(128) NOT NULL default '',
catediscount_groups_id INT(11) NOT NULL default '0',
catediscount_customers_id INT(11) NOT NULL default '0',
catediscount_categories_id INT(11) NOT NULL default '0',
catediscount_discount DECIMAL(8,2) NOT NULL default '-0',
PRIMARY KEY (catediscount_id)
) TYPE=MyISAM;
DELETE from configuration_group WHERE configuration_group_title="TotalB2B";
INSERT INTO configuration_group VALUES ('', 'TotalB2B', 'TotalB2B - configuration options', 1, 1);
UPDATE configuration_group SET sort_order=last_insert_id() WHERE configuration_group_id=last_insert_id();
INSERT INTO `configuration` (`configuration_id`, `configuration_title`, `configuration_key`, `configuration_value`, `configuration_description`, `configuration_group_id`, `sort_order`, `last_modified`, `date_added`, `use_function`, `set_function`) VALUES
('', 'Number Of Prices Per Products', 'XPRICES_NUM', '1', 'Number of prices per products<br><br><b>WARNING: Changing this value will delete prices entry in products table!</b><br><br><b>Every groups that use a deleted price will use product default price.</b>', (SELECT configuration_group_id FROM configuration_group WHERE configuration_group_title = 'TotalB2B'), '31', '2003-11-11 18:33:04', '0000-00-00 00:00:00', 'tep_update_prices', 'tep_cfg_pull_down_prices(')
, ('', 'Allow Guest To See Prices', 'ALLOW_GUEST_TO_SEE_PRICES', 'false', 'Allow guests to view default prices', (SELECT configuration_group_id FROM configuration_group WHERE configuration_group_title = 'TotalB2B'), '32', '', '2004-03-15 14:59:05', NULL, 'tep_cfg_select_option(array(\'true\', \'false\'),')
, ('', 'Guest Discount', 'GUEST_DISCOUNT', '0', 'Guest discount', (SELECT configuration_group_id FROM configuration_group WHERE configuration_group_title = 'TotalB2B'), '33', '', '2004-03-15 14:59:05', NULL, '')
, ('', 'Special price (products price hiding)', 'SPECIAL_PRICES_HIDE', 'false', 'Special price (products price hiding)', (SELECT configuration_group_id FROM configuration_group WHERE configuration_group_title = 'TotalB2B'), '34', '', '2004-03-15 14:59:05', NULL, 'tep_cfg_select_option(array(\'true\', \'false\'),')
, ('', 'New customer Enable', 'NEW_CUSTOMERS_ENABLED', 'false', 'Enable or disable new customers after their registration', (SELECT configuration_group_id FROM configuration_group WHERE configuration_group_title = 'TotalB2B'), '35', '', '2004-03-15 14:59:05', NULL, 'tep_cfg_select_option(array(\'true\', \'false\'),');
I need help to solve this problem.
I thank you all.