Results 1 to 3 of 3
  1. #1
    Join Date
    Jul 2006
    Location
    UK
    Posts
    165
    Plugin Contributions
    0

    Default Import Categories Description Mysql

    Hi

    I am trying to import the categories descriptions using phpmyadmin and have the following text file:

    --
    -- Table structure for table `categories_description`
    --

    CREATE TABLE `categories_description` (
    `categories_id` int(11) NOT NULL default '0',
    `language_id` int(11) NOT NULL default '1',
    `categories_name` varchar(32) NOT NULL default '',
    `categories_description` text NOT NULL,
    PRIMARY KEY (`categories_id`,`language_id`),
    KEY `idx_categories_name_zen` (`categories_name`)
    ) TYPE=MyISAM;

    --
    -- Dumping data for table `categories_description`
    --

    INSERT INTO `categories_description` (`categories_id`, `language_id`, `categories_name`, `categories_description`)
    VALUES
    (1, 1, 'Acid Techno', ''),
    (2, 1, 'Breakbeat', ''),
    (3, 1, 'Classic Rave', ''),
    (4, 1, 'Commercial Trance', ''),
    (5, 1, 'Deep House', ''),
    (6, 1, 'Deep Techno', ''),
    (7, 1, 'Downtempo', ''),
    (8, 1, 'Drum & Bass', ''),
    (9, 1, 'Electro House', ''),
    (10, 1, 'Euro Trance', ''),
    (11, 1, 'Funky House', ''),
    (12, 1, 'Funky Techno', ''),
    (13, 1, 'Gabba', ''),
    (14, 1, 'Hard House', ''),
    (15, 1, 'Hard Core', ''),
    (16, 1, 'Test1', ''),
    (17, 1, 'Hard Techno', ''),
    (18, 1, 'Hard Trance', ''),
    (19, 1, 'Test2', ''),
    (20, 1, 'Hardstyle', ''),
    (21, 1, 'Hardtrance / Techno', ''),
    (22, 1, 'Progressive House', ''),
    (23, 1, 'Scratchtools', ''),
    (24, 1, 'Tech/Hard/Euro/Vocal', ''),
    (25, 1, 'Tech House', ''),
    (26, 1, 'Tech Trance', ''),
    (27, 1, 'Tech/US House', ''),
    (28, 1, 'Techno', ''),
    (29, 1, 'Tribal House', ''),
    (30, 1, 'US/Tech House', ''),
    (31, 1, 'US House', ''),
    (32, 1, 'Vocal House', ''),
    (33, 1, 'Vocal Trance', ''),
    (34, 1, 'US/25', '');

    Once run, the only categories that actually appear in my sites admin area are numbers 4 & 5.

    I am running Zencart 1.3.7 with mysql 5.0

    Any ideas why please?

    Cheers
    Claire

  2. #2
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: Import Categories Description Mysql

    This is the correct structure for this:

    Code:
    DROP TABLE IF EXISTS `categories`;
    CREATE TABLE IF NOT EXISTS `categories` (
      `categories_id` int(11) NOT NULL auto_increment,
      `categories_image` varchar(64) default NULL,
      `parent_id` int(11) NOT NULL default '0',
      `sort_order` int(3) default NULL,
      `date_added` datetime default NULL,
      `last_modified` datetime default NULL,
      `categories_status` tinyint(1) NOT NULL default '1',
      PRIMARY KEY  (`categories_id`),
      KEY `idx_parent_id_cat_id_zen` (`parent_id`,`categories_id`),
      KEY `idx_status_zen` (`categories_status`),
      KEY `idx_sort_order_zen` (`sort_order`)
    ) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=68 ;
    
    -- 
    -- Dumping data for table `categories`
    -- 
    
    INSERT INTO `categories` (`categories_id`, `categories_image`, `parent_id`, `sort_order`, `date_added`, `last_modified`, `categories_status`) VALUES 
    (1, 'categories/category_hardware.gif', 0, 1, '2003-12-23 03:18:19', '2004-05-21 00:32:17', 1),
    (2, 'categories/category_software.gif', 0, 2, '2003-12-23 03:18:19', '2004-05-22 21:14:57', 1),

  3. #3
    Join Date
    Jul 2006
    Location
    UK
    Posts
    165
    Plugin Contributions
    0

    Default Re: Import Categories Description Mysql

    Many thanks!


 

 

Similar Threads

  1. MYSQL Import Error
    By infowire in forum Installing on a Windows Server
    Replies: 8
    Last Post: 29 Dec 2009, 06:00 PM
  2. Import Datafeed to MySQL database?
    By kirei in forum Setting Up Categories, Products, Attributes
    Replies: 2
    Last Post: 27 Nov 2009, 10:09 PM
  3. MySQL database import error
    By xikan in forum Installing on a Linux/Unix Server
    Replies: 1
    Last Post: 24 Aug 2009, 02:39 AM
  4. Unable to import MYSQL database
    By 1just4help in forum Installing on a Windows Server
    Replies: 25
    Last Post: 2 Jun 2009, 06:29 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg