7tech Posted April 27, 2008 Posted April 27, 2008 Hi Folks, :rolleyes: I need help....I am trying to install a contribution for referral points and it has a file that needs to be addeed to the database. I have a working OSCommerce site and I am not sure how to alter the databse. I have the access to myphp admin though. Here is the database code: ALTER TABLE customers ADD customers_referral_id CHAR(8) NOT NULL; ALTER TABLE customers ADD customers_referral_points INT DEFAULT 0 NOT NULL; INSERT INTO configuration_group (configuration_group_title, configuration_group_description, sort_order, visible) VALUES ('Referral Options', 'Configuration for the referral system', '16', '1'); SELECT @optID:=configuration_group_id FROM configuration_group WHERE configuration_group_title = 'Referral Options'; INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function) VALUES ('Enable Referral System', 'USE_REFERRAL_SYSTEM', 'false', 'Whether the referral system is enabled for use.', @optID, '50', 'tep_cfg_select_option(array(\'true\', \'false\'),'); INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order) VALUES ('Referral Point Value', 'REFERRAL_POINT_VALUE', '1.00', 'The value of the referral point.', @optID, '51'); INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function) VALUES ('Referral ID Method', 'REFERRAL_ID_METHOD', 'auto', 'The method to use to determine the referral id. ([<b>auto<//b>] generate, account [<b>email<//b>], [<b>user<//b>] entered)', @optID, '52', 'tep_cfg_select_option(array(\'auto\', \'email\', \'user\'),'); INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order) VALUES ('Referral ID Min Length', 'REFERRAL_ID_MIN_LENGTH', '8', 'This number represents the minimum length the referral id can be.', @optID, '53'); INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function) VALUES ('Referral Accepted at ', 'REFERRAL_ACCEPT_METHOD', 'checkout', 'This determines where the referral code will be accepted. ([<b>account<//b>] creation, at [<b>checkout<//b>]', @optID, '54', 'tep_cfg_select_option(array(\'checkout\', \'account\'),'); This is my first ever post to the forum and I hope i will get a lot of help.......thanks in advance.......
Guest Posted April 27, 2008 Posted April 27, 2008 Use phpMyAdmin. Select the user to configure database via phpMyAdmin and click on the Login icon. A new window should open for phpMyAdmin. In some cases, you may have to choose which database your OSC tables are located on. If this is the case, please choose the database from the list or the drop down box at the left. To run a SQL query, click on "SQL" on the navigation bar (on the right side, click on the SQL tab at the top). Then copy the code from the sql file and paste the code into the textarea on that page. Click on the GO button and it is done. If all goes well, your SQL query will now be succesfully entered.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.