Answer the question
In order to leave comments, you need to log in
How to insert the value of a variable into the database using peewee?
In my script, I am getting a user variable which is a database field. It changes every time. After getting this variable, I need to insert the value into the database, into this field. I tried to do it as usual:
# Получение значения переменной user
record = Table.get(Table.user_id == id)
record.user = 15
record.save()
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question