upgrade

The upgrade module provides a way for the database and schema that is the backend for the Songs plugin

openlp.plugins.songs.lib.upgrade.upgrade_1(session, metadata)[source]

Version 1 upgrade.

This upgrade removes the many-to-many relationship between songs and media_files and replaces it with a one-to-many, which is far more representative of the real relationship between the two entities.

In order to facilitate this one-to-many relationship, a song_id column is added to the media_files table, and a weight column so that the media files can be ordered.

Parameters:
  • session
  • metadata
openlp.plugins.songs.lib.upgrade.upgrade_2(session, metadata)[source]

Version 2 upgrade.

This upgrade adds a create_date and last_modified date to the songs table

openlp.plugins.songs.lib.upgrade.upgrade_3(session, metadata)[source]

Version 3 upgrade.

This upgrade adds a temporary song flag to the songs table

openlp.plugins.songs.lib.upgrade.upgrade_4(session, metadata)[source]

Version 4 upgrade.

This upgrade adds a column for author type to the authors_songs table

openlp.plugins.songs.lib.upgrade.upgrade_5(session, metadata)[source]

Version 5 upgrade.

This upgrade adds support for multiple songbooks

openlp.plugins.songs.lib.upgrade.upgrade_6(session, metadata)[source]

Version 6 upgrade

This version corrects the errors in upgrades 4 and 5