Reputation: 145
I want to create a table as below:
import sqlite3 as sql
con = sql.connect('test.db')
cur = con.cursour()
sql_command = "create table test(dose float, Dose float, DOSE float)"
cur.execute(sql_command)
But i got an error: OperationalError: duplicate column name: Dose. I wonder how to make the table title case-sensitive?
Upvotes: 3
Views: 4659
Reputation: 4551
Sqlite column names are case-insensitive, according to this. I think it is enforced on C level of implementation.
As a side-note, mixing column names dose
, Dose
, etc does not seem a great idea even if permitted, unless as an exploratory exercise.
Also this can be useful: Is SQL syntax case sensitive?
Upvotes: 4