![]() |
SQLite NO column exists - Printable Version +- Python Forum (https://python-forum.io) +-- Forum: Python Coding (https://python-forum.io/forum-7.html) +--- Forum: General Coding Help (https://python-forum.io/forum-8.html) +--- Thread: SQLite NO column exists (/thread-5913.html) |
SQLite NO column exists - rachitmishra25 - Oct-27-2017 I am trying to insert values into a SQLite DB integrated with Python. I have done that successsfully for most of the tables with an exception of one which has a column name: TOB-2/-2a_Measure_Desc This snippet shows the fragment where I am making the insertions index = "%s__%s" % (tablename, col) sql_query = "CREATE INDEX %s on %s (%s)" % (index, tablename, col) cursor.execute(sql_query) print(tablename) #print(error) insert_values = "INSERT INTO %s VALUES (%s)" % (tablename, ", ".join([ "?" for col in row ]))
RE: SQLite NO column exists - Larz60+ - Oct-27-2017 you can do the following:
|