Sep-25-2017, 05:07 PM
Does it fail for the first table, or the second?
Have you tried adding a semicolon to the end of the statement, to let sqlite know it's the end of the statement? I don't know a lot about sqlite, but it could just be batching all the execute statements together, and actually executing them at the same time when the transaction commits (... which might be when the cursor falls out of scope).
Add a call to
Have you tried adding a semicolon to the end of the statement, to let sqlite know it's the end of the statement? I don't know a lot about sqlite, but it could just be batching all the execute statements together, and actually executing them at the same time when the transaction commits (... which might be when the cursor falls out of scope).
Add a call to
print
with the sql statement just before calling execute
, so we can see if it fails the first time around, or the second.