Hopefully I can explain this correctly. I am trying to take a MySQL select statement, get the output into a list, then upload that list back to the MySQL server.
This spits out a tuple of integers ...
((1L,), (2L,), (3L,), (4L,), (5L,), (6L,), (7L,), (8L,), (9L,), (10L,), (11L,))
... with an 'L' following each one.
But I want to update the database with this set as:
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11
At first I thought I had it, but each converted row of tuples was the same thing even though the actually data pulled had changed. Anyone have any ideas how to do this?
Code:
cursor.execute("SELECT stuff FROM place WHERE thing = 3 ORDER BY track_id ASC")
((1L,), (2L,), (3L,), (4L,), (5L,), (6L,), (7L,), (8L,), (9L,), (10L,), (11L,))
... with an 'L' following each one.
But I want to update the database with this set as:
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11
At first I thought I had it, but each converted row of tuples was the same thing even though the actually data pulled had changed. Anyone have any ideas how to do this?
Comment