-- MySQL dump 9.11
--
-- Host: localhost    Database: freedb
-- ------------------------------------------------------
-- Server version       4.0.22

--
-- Current Database: freedb
--

CREATE DATABASE /*!32312 IF NOT EXISTS*/ freedb;

USE freedb;

--
-- Table structure for table `albums`
--

CREATE TABLE albums (
  id bigint(20) NOT NULL auto_increment,
  discid varchar(8) default NULL,
  dtitle varchar(255) default NULL,
  dyear varchar(4) default NULL,
  dgenre varchar(255) default NULL,
  extd text,
  PRIMARY KEY  (id),
  KEY discid (discid(5))
) TYPE=MyISAM;

--
-- Table structure for table `tracks`
--

CREATE TABLE tracks (
  id bigint(20) NOT NULL auto_increment,
  fkey varchar(8) default NULL,
  track_number int(4) NOT NULL default '0',
  track_name varchar(255) default NULL,
  track_info text,
  PRIMARY KEY  (id),
  KEY fkey (fkey(5))
) TYPE=MyISAM;


--
-- Create the user which the software will use to talk to the db
--

GRANT ALL ON freedb.* TO root@'%' IDENTIFIED BY 'demode';

--
-- Create the indices for the albums and tracks tables
--

CREATE INDEX discid ON albums(discid(5));
CREATE INDEX fkey ON tracks(fkey(5));
