System: |
|
Fields
idEpisode |
integer |
|
|
|
|
|
|
|
idShow |
integer |
|
|
|
|
|
|
|
idFile |
integer |
|
|
|
|
|
|
|
idSource |
integer |
|
|
|
|
|
|
|
Episode |
integer |
|
|
|
|
|
|
|
Title |
text |
|
|
|
|
|
|
|
New |
bool |
|
|
|
0 |
|
|
|
Mark |
bool |
|
|
|
0 |
|
|
|
Lock |
bool |
|
|
|
0 |
|
|
|
Season |
integer |
|
|
|
|
|
|
|
Rating |
text |
|
|
|
|
|
|
|
Plot |
text |
|
|
|
|
|
|
|
Aired |
text |
|
|
|
|
|
|
|
NfoPath |
text |
|
|
|
|
|
|
|
Playcount |
integer |
|
|
|
|
|
|
|
DisplaySeason |
integer |
|
|
|
|
|
|
|
DisplayEpisode |
integer |
|
|
|
|
|
|
|
DateAdded |
integer |
|
|
|
|
|
|
|
Runtime |
text |
|
|
|
|
|
|
|
Votes |
text |
|
|
|
|
|
|
|
VideoSource |
text |
|
|
|
|
|
|
|
HasSub |
bool |
|
|
|
0 |
|
|
|
SubEpisode |
integer |
|
|
|
|
|
|
|
iLastPlayed |
integer |
|
|
|
|
|
|
|
strIMDB |
text |
|
|
|
|
|
|
|
strTMDB |
text |
|
|
|
|
|
|
|
strTVDB |
text |
|
|
|
|
|
|
|
iUserRating |
integer |
|
|
|
0 |
|
|
|
OriginalTitle |
text |
|
|
|
|
|
|
|
userNote |
|
|
|
|
|
|
|
|
Indexes
There are no indexes for table "episode"
Foreign keys
There are no foreign keys for table "episode"
Checks
There are no checks for table "episode"
Triggers
References
There are no references for table "episode"
Definition:
CREATE TABLE episode (
idEpisode integer PRIMARY KEY AUTOINCREMENT,
idShow integer NOT NULL,
idFile integer NOT NULL,
idSource integer NOT NULL,
Episode integer,
Title text,
"New" bool DEFAULT 0,
Mark bool NOT NULL DEFAULT 0,
Lock bool NOT NULL DEFAULT 0,
Season integer,
Rating text,
Plot text,
Aired text,
NfoPath text,
Playcount integer,
DisplaySeason integer,
DisplayEpisode integer,
DateAdded integer,
Runtime text,
Votes text,
VideoSource text,
HasSub bool NOT NULL DEFAULT 0,
SubEpisode integer,
iLastPlayed integer,
strIMDB text,
strTMDB text,
strTVDB text,
iUserRating integer NOT NULL DEFAULT 0,
OriginalTitle text,
userNote
);
CREATE TRIGGER delete_episode
AFTER DELETE
ON episode
BEGIN
DELETE FROM actorlinkepisode WHERE idEpisode=old.idEpisode;
DELETE FROM art WHERE media_id=old.idEpisode AND media_type='episode';
DELETE FROM directorlinkepisode WHERE idEpisode=old.idEpisode;
DELETE FROM files WHERE idFile=old.idFile;
DELETE FROM rating WHERE media_id=old.idEpisode AND media_type='episode';
DELETE FROM gueststarlinkepisode WHERE idEpisode=old.idEpisode;
DELETE FROM uniqueid WHERE media_id=old.idEpisode AND media_type='episode';
DELETE FROM writerlinkepisode WHERE idEpisode=old.idEpisode;
DELETE FROM TVVStreams WHERE TVEpID=old.idEpisode;
DELETE FROM TVAStreams WHERE TVEpID=old.idEpisode;
DELETE FROM TVSubs WHERE TVEpID=old.idEpisode;
END;