I have a UNIQUE TEXT
column (“name”) in SQLite for one of my tables (let’s call it “table A”) and i’m considering using that column as the key for the table
The reason i can see for continue using a standard “rowid column” (integer with autoincrement) is that the name could change and in these cases i will have to update the tables which holds relations to table A
And the reason for using the TEXT column as key is that it takes less space, and makes things more elegant in the database (though less elegant in my Python code since i would need to make additional updates)
Are there other things to consider? What choice would you make and would it depend on the number of other tables referencing table A?