Once we have data in the database that we don't want to lose, if we need to modify the database schema then we need to migrate the data to the new schema.
For simple changes during development it is probably simplest to just directly modify the database accordingly.
But if this has to be done in production, a common way to do this is using alembic:
Once we have data in the database that we don't want to lose, if we need to modify the database schema then we need to migrate the data to the new schema.
For simple changes during development it is probably simplest to just directly modify the database accordingly.
But if this has to be done in production, a common way to do this is using alembic:
https://alembic.sqlalchemy.org/en/latest/