Hey guys, I recently decided to learn Python and SQL, and I'm running into an issue. I believe it's on the SQL end and not Python. I'm using SQLite3, and when I try to grab a column and place it into a tuple, everything is fine. However, if I try to create a second tuple and toss another column in there, it seems as if SQL is overwriting both tuples with the last column read.

So basically, I work at a vape shop and I'm trying to grab some information from the database and do something with it. One column is flavor names, the second one is number of bottles sold:


conn = sqlite3.connect('flavors.db')                            
c = conn.cursor()

if os.path.isfile('flavors.db'):                                
    pass                                                        
else:                                                          
    c.execute('CREATE TABLE juice(name text, sold real)')  

c.executemany('INSERT INTO juice VALUES (?,?)', flavors)  

juice_name = c.execute('SELECT name FROM juice')            
juice_sold = c.execute('SELECT sold FROM juice')

for n in juice_name:                                        
    print(str("").join(n))                      

I know the if-else part is a mess, but I'll fix that later. It functions for now. If I comment out

juice_sold = c.execute('SELECT sold FROM juice')

I get a nice list of flavor names. If I don't, I get an error: 

Traceback (most recent call last):
  File "/Users/**********/PycharmProjects/Juice_SQL/Juice_Trends.py", line 74, in <module>
    print(str("").join(n))                            
TypeError: sequence item 0: expected str instance, float found

If anyone could give me an idea of what's going on here, and how to fix it, I'd really appreciate it.