Hello i am new in python and im trying to learn basic things, right now i have made a query that gets chat_ID from database and i want to insert all the results inside an array but i cant make the values enter inside the array, this is the code i have done until now:
query = "SELECT `chatid` FROM `chats`"
cursor = await self.db.execute(query)
record = await cursor.fetchall()
for row in record:
chats_id = [row] #the array
I want the result to be
chats_id = ["1","2","3","4"];
chats_id = list(row)?print(chats_id)to get["1"], ["2"]...