最佳答案
I need to query a SQLAlchemy database by its id
something similar to
User.query.filter_by(username='peter')
but for id. How do I do this? [Searching over Google and SO didn't help]