porridger/back/delete_all_poems.py

7 lines
154 B
Python

from .models import Poems
from .db import database
to_delete = database.query(Poems).filter(Poems.id > 110)
database.delete(to_delete)
database.commit()