Uploaded image for project: 'MusicBrainz Server'
  1. MusicBrainz Server
  2. MBS-10178

Create a genre_alias table

    XMLWordPrintable

    Details

      Description

      For MBS-10062 we need a table:

      CREATE TABLE genre_alias ( -- replicate (verbose)
          id                  SERIAL,
          genre               INTEGER NOT NULL, -- references genre.id
          name                VARCHAR NOT NULL,
          locale              TEXT,
          edits_pending       INTEGER NOT NULL DEFAULT 0 CHECK (edits_pending >= 0),
          last_updated        TIMESTAMP WITH TIME ZONE DEFAULT NOW(),
          primary_for_locale  BOOLEAN NOT NULL DEFAULT FALSE,
          CONSTRAINT primary_check CHECK ((locale IS NULL AND primary_for_locale IS FALSE) OR (locale IS NOT NULL))
      );
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                reosarevok Nicolás Tamargo
                Reporter:
                reosarevok Nicolás Tamargo
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Packages

                  Version Package
                  Schema change, 2019 Q2