User:RobertKaye/Schema Change Release May 2012

From MusicBrainz Wiki
Jump to navigationJump to search

Tickets under consideration for May 15 2012

Conflict tickets

This ticket is a lot of work and may conflict with a Summer of Code proposal:

I'm unsure how to proceed with this ticket.

Clearly stated tickets

These tickets appear to be cleanly stated and nearly actionable:

http://tickets.musicbrainz.org/browse/MBS-2885

Database changes
CREATE TABLE iswc
(
    id             SERIAL,
    work           INTEGER,
    iswc           CHARACTER(15),
    source         SMALLINT,
    edits_pending  INTEGER,
    created        TIMESTAMP WITH TIME ZONE
);
ALTER TABLE work DROP COLUMN iswc;
  • TODO: Clarify constraints, clarify primary key

http://tickets.musicbrainz.org/browse/MBS-2851

Database changes
CREATE TABLE timeline_event (
    event_date DATE PRIMARY KEY,
    event TEXT NOT NULL,
    description TEXT NOT NULL,
    link TEXT NOT NULL
);
  • TODO: Does this belong in the musicbrainz schema?

http://tickets.musicbrainz.org/browse/MBS-2532

Database changes
  • Still too much in discussion

http://tickets.musicbrainz.org/browse/MBS-3788

Database changes

The changes just for artists are:

CREATE TABLE artist_alias_type (
    id SERIAL NOT NULL PRIMARY KEY,
    name TEXT NOT NULL
);

ALTER TABLE artist_alias ADD COLUMN type INTEGER;
ALTER TABLE artist_alias ADD COLUMN sort_name INTEGER NOT NULL;
ALTER TABLE artist_alias ADD COLUMN begin_date_year SMALLINT;
ALTER TABLE artist_alias ADD COLUMN begin_date_month SMALLINT;
ALTER TABLE artist_alias ADD COLUMN begin_date_day SMALLINT;
ALTER TABLE artist_alias ADD COLUMN end_date_year SMALLINT;
ALTER TABLE artist_alias ADD COLUMN end_date_month SMALLINT;
ALTER TABLE artist_alias ADD COLUMN end_date_day SMALLINT;
ALTER TABLE artist_alias ADD COLUMN primary_for_locale BOOLEAN NOT NULL DEFAULT false;

ALTER TABLE artist_alias ADD CONSTRAINT primary_check
CHECK (locale IS NULL AND primary_for_locale IS FALSE);  

DROP INDEX artist_alias_idx_locale_artist;

CREATE UNIQUE INDEX artist_alias_idx_primary ON artist_alias (artist, locale) WHERE primary_for_locale = TRUE AND locale IS NOT NULL;
  • TODO: Decide on whether we need separate type tables for each entity, or if they can share a type table

http://tickets.musicbrainz.org/browse/MBS-842

Database Changes

(Leaving for warp)

http://tickets.musicbrainz.org/browse/MBS-3646

Database Changes

http://tickets.musicbrainz.org/browse/MBS-1799

Database Changes

http://tickets.musicbrainz.org/browse/MBS-1798

Database Changes
ALTER TABLE work ADD COLUMN language INTEGER;
ALTER TABLE work ADD CONSTRAINT work_fk_language FOREIGN KEY (language) REFERENCES language (id);

http://tickets.musicbrainz.org/browse/MBS-1385

Database Changes
ALTER TABLE link ADD COLUMN finished BOOLEAN NOT NULL DEFAULT FALSE;
ALTER TABLE artist ADD COLUMN finished BOOLEAN NOT NULL DEFAULT FALSE;
ALTER TABLE label ADD COLUMN finished BOOLEAN NOT NULL DEFAULT FALSE;

http://tickets.musicbrainz.org/browse/MBS-4337

Database Changes

Next Steps

For each of these tickets, we will require the following two pieces of work:

  • Oliver and Warp will review these tickets and sanity check the proposed schema changes. Due date: 29 March
  • Specify exactly what the user interface changes will be. Mock ups would be great. Due date: 2 April


Tickets that do not provide the required information by the given due date will be removed from the 2012-05-15 schema change.