Files
pyfa/eos/db/migrations/upgrade16.py
Resin Neublem 78cbed516a Adds a new notes pane for each fit
This allows users to save text notes for each fit. They may do this for history, or usage, etc.
2016-11-20 14:11:42 -05:00

15 lines
370 B
Python

"""
Migration 16
- Alters fits table to introduce notes attribute
"""
import sqlalchemy
def upgrade(saveddata_engine):
# Update fits schema to include notes attribute
try:
saveddata_engine.execute("SELECT notes FROM fits LIMIT 1")
except sqlalchemy.exc.DatabaseError:
saveddata_engine.execute("ALTER TABLE fits ADD COLUMN notes VARCHAR;")