I am trying to make a ChatBot but I've run into a small problem. I have a nested or loop in python and it's supposed to cycle through a sqlite table that had all the names of other table. The inner for loop cycles through the table inside the first one, iterating over cells.
for i in c.execute("""SELECT * FROM triggers_sql"""):
for l in c.execute("""SELECT * FROM "{}" """.format(i)):
print(i, l)
However, for some reason, the outer for loop only cycles through the first cell of the first table. I can't think of anything that I've done wrong here.