Answer the question
In order to leave comments, you need to log in
Convert data from db to json in python?
Good
Is there a library to convert strings from the database to json format, otherwise I haven’t figured out how to collect it with handles yet, the output should be like this, the column name and the string value
Answer the question
In order to leave comments, you need to log in
select json_agg(tablename) from tablename;
Everything. Get json array.
https://marshmallow.readthedocs.io/en/latest/
https://flask-marshmallow.readthedocs.io/en/latest/
I think something like this:
connecror.exec("SELECT * FROM table")
json.dumps(connector.fetchall())
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question