1
0
mirror of https://github.com/spl0k/supysonic.git synced 2024-12-23 17:36:19 +00:00
supysonic/schema/migration/20171022.mysql.sql

12 lines
227 B
MySQL
Raw Normal View History

START TRANSACTION;
ALTER TABLE playlist ADD tracks TEXT;
UPDATE playlist SET tracks = (
SELECT GROUP_CONCAT(track_id SEPARATOR ',')
FROM playlist_track
WHERE playlist_id = playlist.id);
DROP TABLE playlist_track;
COMMIT;