While reading through python sqlite3 DB-API, the first example of creating table uses thee single quotes:
c.execute('''CREATE TABLE stocks
(date text, trans text, symbol text, qty real, price real)''')
But in other examples there are double quotes:
cur.execute("create table people (name_last, age)")
So I've got 2 questions:
- It this really any difference? How can it affect
create tablecommand? Which one is better to use with parameters? ex.:
c.execute('''CREATE TABLE %s(date text, trans text, symbol text, qty real, price real)''' % table_name)
VS.
cur.execute("create table %s (name_last, age)" % table_name)
Thanks