Answer the question
In order to leave comments, you need to log in
Why is an array returned in flask sqlalchemy?
Here is the request.
user_id = L.query.with_entities(L.user_id).filter(L.identity == j['identity'], L.provider == j['provider']).first()
(2,)
Answer the question
In order to leave comments, you need to log in
Then do it like this:
For example:
or immediately:
user_id = L.query.with_entities(L.user_id).filter(L.identity == j['identity'], L.provider == j['provider']).first()[0]
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question