SyntaxFix
Write A Post
Hire A Developer
Questions
You can do this,
User.query.filter_by(id=123).delete()
or
User.query.filter(User.id == 123).delete()
Make sure to commit for delete() to take effect.
commit
delete()