Warning
This document is for an old release of Galaxy. You can alternatively view this page in the latest release if it exists or view the top of the latest release's documentation.
Source code for galaxy.model.migrate.versions.0069_rename_sequencer_form_type
"""
Migration script to rename the sequencer information form type to external service information form
"""
import logging
from sqlalchemy import MetaData
log = logging.getLogger(__name__)
metadata = MetaData()
[docs]def upgrade(migrate_engine):
metadata.bind = migrate_engine
print(__doc__)
metadata.reflect()
current_form_type = 'Sequencer Information Form'
new_form_type = "External Service Information Form"
cmd = f"update form_definition set type='{new_form_type}' where type='{current_form_type}'"
migrate_engine.execute(cmd)
[docs]def downgrade(migrate_engine):
metadata.bind = migrate_engine
metadata.reflect()
new_form_type = 'Sequencer Information Form'
current_form_type = "External Service Information Form"
cmd = f"update form_definition set type='{new_form_type}' where type='{current_form_type}'"
migrate_engine.execute(cmd)