From 2d7297e3b7b621e6d851cb5cf1a29b395c4de842 Mon Sep 17 00:00:00 2001 From: Ignace Date: Sat, 3 Jan 2026 16:39:01 +0100 Subject: [PATCH] updated query -2- --- update_db.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/update_db.py b/update_db.py index 5638b51..e0817f3 100644 --- a/update_db.py +++ b/update_db.py @@ -9,4 +9,8 @@ items = db.session.scalars(query).all() # items=Item.query.filter_by(quantity='').all() for i in items: - print(f"{i.label} {i.quantity} {i.unit}") \ No newline at end of file + print(f"{i.label} {i.quantity} {i.unit}") + i.quantity = 1 + i.unit = 'x' + +db.session.commit() \ No newline at end of file