diff --git a/update_db.py b/update_db.py index 27b2260..5638b51 100644 --- a/update_db.py +++ b/update_db.py @@ -4,7 +4,7 @@ from models import db, Item app = create_app() app.app_context().push() -query = sa.select(Item) #.where(Item.quantity == 0) +query = sa.select(Item).where(Item.quantity == 0) items = db.session.scalars(query).all() # items=Item.query.filter_by(quantity='').all()