Answer the question
In order to leave comments, you need to log in
How not to stop the database?
There is a code
@bot.message_handler(commands=['start'])
def welc(message):
idUser = message.from_user.id
userName = message.from_user.first_name
bot.send_message(message.chat.id, "Что хотите узнать?")
cur.execute("INSERT INTO users(username, id_tele) VALUES(?, ?)", (userName, idUser))
cur.close()
conn.commit()
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