Reply to thread

Hi,


The ID comes from recording.idRecording which is the primary key for that table. For SQLite this is a special (non-typeless, unlike all the other datatypes) datatype which  functions as an AUTOINCREMENT feature. So, inserting NULL into the recording/recorded table should result into a unique next value. Judging by the information you give, this functionality somehow got lost in your TVDatabase.


Now you can delete the TVDatabase (and loose all tv channels, groups, program info etc.) by deleting the TVDatabaseV21.db3 from the database directory.


If you don't want that, you can also try to drop and recreate the two tables which hopefully brings back the AUTOINCREMENT functionality:

[code]DROP TABLE recording;

DROP TABLE recorded;

CREATE TABLE recording ( idRecording integer primary key, idChannel integer, iRecordingType integer, strProgram text, iStartTime integer, iEndTime integer, iCancelTime integer, bContentRecording integer, priority integer, quality integer, episodesToKeep integer);

CREATE TABLE recorded ( idRecorded integer primary key, idChannel integer, idGenre integer, strProgram text, iStartTime integer, iEndTime integer, strDescription text, strFileName text, iPlayed integer);

[/code]


Kind regards,

Michel


Top Bottom