DBIx-Class-ResultSet-RecursiveUpdate

 view release on metacpan or  search on metacpan

t_dbic/lib/sqlite.sql  view on Meta::CPAN


CREATE INDEX cd_idx_genreid ON cd (genreid);

CREATE INDEX cd_idx_single_track ON cd (single_track);

CREATE UNIQUE INDEX cd_artist_title ON cd (artist, title);

--
-- Table: collection_object
--
CREATE TABLE collection_object (
  collection integer NOT NULL,
  object integer NOT NULL,
  PRIMARY KEY (collection, object)
);

CREATE INDEX collection_object_idx_collection ON collection_object (collection);

CREATE INDEX collection_object_idx_object ON collection_object (object);

--
-- Table: lyrics
--
CREATE TABLE lyrics (
  lyric_id INTEGER PRIMARY KEY NOT NULL,
  track_id integer NOT NULL
);

CREATE INDEX lyrics_idx_track_id ON lyrics (track_id);

--
-- Table: cd_artwork
--
CREATE TABLE cd_artwork (
  cd_id INTEGER PRIMARY KEY NOT NULL
);

--
-- Table: liner_notes
--
CREATE TABLE liner_notes (
  liner_id INTEGER PRIMARY KEY NOT NULL,
  notes varchar(100) NOT NULL
);

--
-- Table: lyric_versions
--
CREATE TABLE lyric_versions (
  id INTEGER PRIMARY KEY NOT NULL,
  lyric_id integer NOT NULL,
  text varchar(100) NOT NULL
);

CREATE INDEX lyric_versions_idx_lyric_id ON lyric_versions (lyric_id);

--
-- Table: tags
--
CREATE TABLE tags (
  tagid INTEGER PRIMARY KEY NOT NULL,
  cd integer NOT NULL,
  tag varchar(100) NOT NULL
);

CREATE INDEX tags_idx_cd ON tags (cd);

CREATE UNIQUE INDEX tagid_cd ON tags (tagid, cd);

CREATE UNIQUE INDEX tagid_cd_tag ON tags (tagid, cd, tag);

CREATE UNIQUE INDEX tags_tagid_tag ON tags (tagid, tag);

CREATE UNIQUE INDEX tags_tagid_tag_cd ON tags (tagid, tag, cd);

--
-- Table: cd_to_producer
--
CREATE TABLE cd_to_producer (
  cd integer NOT NULL,
  producer integer NOT NULL,
  attribute integer,
  PRIMARY KEY (cd, producer)
);

CREATE INDEX cd_to_producer_idx_cd ON cd_to_producer (cd);

CREATE INDEX cd_to_producer_idx_producer ON cd_to_producer (producer);

--
-- Table: images
--
CREATE TABLE images (
  id INTEGER PRIMARY KEY NOT NULL,
  artwork_id integer NOT NULL,
  name varchar(100) NOT NULL,
  data blob
);

CREATE INDEX images_idx_artwork_id ON images (artwork_id);

--
-- Table: twokeys
--
CREATE TABLE twokeys (
  artist integer NOT NULL,
  cd integer NOT NULL,
  PRIMARY KEY (artist, cd)
);

CREATE INDEX twokeys_idx_artist ON twokeys (artist);

--
-- Table: artwork_to_artist
--
CREATE TABLE artwork_to_artist (
  artwork_cd_id integer NOT NULL,
  artist_id integer NOT NULL,
  PRIMARY KEY (artwork_cd_id, artist_id)
);

CREATE INDEX artwork_to_artist_idx_artist_id ON artwork_to_artist (artist_id);

CREATE INDEX artwork_to_artist_idx_artwork_cd_id ON artwork_to_artist (artwork_cd_id);

--
-- Table: fourkeys_to_twokeys
--
CREATE TABLE fourkeys_to_twokeys (
  f_foo integer NOT NULL,
  f_bar integer NOT NULL,
  f_hello integer NOT NULL,
  f_goodbye integer NOT NULL,
  t_artist integer NOT NULL,



( run in 1.979 second using v1.01-cache-2.11-cpan-97f6503c9c8 )