File: schema-21.sql

package info (click to toggle)
strawberry 1.2.17-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 29,416 kB
  • sloc: cpp: 105,282; sql: 1,949; ansic: 776; xml: 421; sh: 388; makefile: 7
file content (43 lines) | stat: -rw-r--r-- 1,172 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
DROP INDEX IF EXISTS idx_albumartistsort;

DROP INDEX IF EXISTS idx_albumsort;

DROP INDEX IF EXISTS idx_artistsort;

DROP INDEX IF EXISTS idx_composersort;

DROP INDEX IF EXISTS idx_performersort;

DROP INDEX IF EXISTS idx_titlesort;

ALTER TABLE %allsongstables ADD COLUMN albumartistsort TEXT;

ALTER TABLE %allsongstables ADD COLUMN albumsort TEXT;

ALTER TABLE %allsongstables ADD COLUMN artistsort TEXT;

ALTER TABLE %allsongstables ADD COLUMN composersort TEXT;

ALTER TABLE %allsongstables ADD COLUMN performersort TEXT;

ALTER TABLE %allsongstables ADD COLUMN titlesort TEXT;

ALTER TABLE %allsongstables ADD COLUMN bpm REAL;

ALTER TABLE %allsongstables ADD COLUMN mood TEXT;

ALTER TABLE %allsongstables ADD COLUMN initial_key TEXT;

CREATE INDEX IF NOT EXISTS idx_albumartistsort ON songs (albumartistsort);

CREATE INDEX IF NOT EXISTS idx_albumsort ON songs (album);

CREATE INDEX IF NOT EXISTS idx_artistsort ON songs (artistsort);

CREATE INDEX IF NOT EXISTS idx_composersort ON songs (title);

CREATE INDEX IF NOT EXISTS idx_performersort ON songs (title);

CREATE INDEX IF NOT EXISTS idx_titlesort ON songs (title);

UPDATE schema_version SET version=21;