easyskankin
09-29-2006, 05:24 AM
Not sure if anyone can help/right place, but:
I need to run an SQL file on a database, which should be/is normally done through phpMyAdmin which I'm not familiar with, and at a quick glance didn't look self-explanatory to me! I'm also learning php as I go... :)
Is there a way to manually run the SQL file, which contains:
-------------------------------------------------------------
DROP TABLE IF EXISTS products_extra_fields;
CREATE TABLE products_extra_fields (
products_extra_fields_id int NOT NULL auto_increment,
products_extra_fields_name varchar(64) NOT NULL default '',
products_extra_fields_order int(3) NOT NULL default '0',
# Change to make the new extra field active by default
# products_extra_fields_status tinyint(1) NOT NULL default '0',
products_extra_fields_status tinyint(1) NOT NULL default '1',
PRIMARY KEY (products_extra_fields_id)
);
DROP TABLE IF EXISTS products_to_products_extra_fields;
CREATE TABLE products_to_products_extra_fields (
products_id int NOT NULL,
products_extra_fields_id int NOT NULL,
products_extra_fields_value varchar(64),
PRIMARY KEY (products_id,products_extra_fields_id)
);
ALTER TABLE `products_extra_fields` ADD `languages_id` INT( 11 ) DEFAULT '0' NOT NULL ;
-------------------------------------------------------------
Many thanks in advance for any help/pointers/decoding of the above into normal-speak(!).
Jon
I need to run an SQL file on a database, which should be/is normally done through phpMyAdmin which I'm not familiar with, and at a quick glance didn't look self-explanatory to me! I'm also learning php as I go... :)
Is there a way to manually run the SQL file, which contains:
-------------------------------------------------------------
DROP TABLE IF EXISTS products_extra_fields;
CREATE TABLE products_extra_fields (
products_extra_fields_id int NOT NULL auto_increment,
products_extra_fields_name varchar(64) NOT NULL default '',
products_extra_fields_order int(3) NOT NULL default '0',
# Change to make the new extra field active by default
# products_extra_fields_status tinyint(1) NOT NULL default '0',
products_extra_fields_status tinyint(1) NOT NULL default '1',
PRIMARY KEY (products_extra_fields_id)
);
DROP TABLE IF EXISTS products_to_products_extra_fields;
CREATE TABLE products_to_products_extra_fields (
products_id int NOT NULL,
products_extra_fields_id int NOT NULL,
products_extra_fields_value varchar(64),
PRIMARY KEY (products_id,products_extra_fields_id)
);
ALTER TABLE `products_extra_fields` ADD `languages_id` INT( 11 ) DEFAULT '0' NOT NULL ;
-------------------------------------------------------------
Many thanks in advance for any help/pointers/decoding of the above into normal-speak(!).
Jon