2015-05-23, 08:33
Hi,
Execute the script provided at the pastepin link. The script at the link you have to execute only one time.
The script will create new Databases. Open the a90 database and execute this code
and this
If you have done this open b90(...c90...d90) do the same job again.
I don't need different profiles on the same box. If you want to change profiles on one box use the profile.xml and the userdata folder.
Execute the script provided at the pastepin link. The script at the link you have to execute only one time.
The script will create new Databases. Open the a90 database and execute this code
Code:
CREATE VIEW `seasonview`
AS SELECT
`seasons`.`idSeason` AS `idSeason`,
`seasons`.`idShow` AS `idShow`,
`seasons`.`season` AS `season`,
`tvshowview`.`strPath` AS `strPath`,
`tvshowview`.`c00` AS `showTitle`,
`tvshowview`.`c01` AS `plot`,
`tvshowview`.`c05` AS `premiered`,
`tvshowview`.`c08` AS `genre`,
`tvshowview`.`c14` AS `strStudio`,
`tvshowview`.`c13` AS `mpaa`,
count(distinct `episodeview`.`idEpisode`) AS `episodes`,count(`files`.`playCount`) AS `playCount` from (((`seasons` join `tvshowview` on((`tvshowview`.`idShow` = `seasons`.`idShow`))) join `episodeview` on(((`episodeview`.`idShow` = `seasons`.`idShow`) and (`episodeview`.`c12` = `seasons`.`season`)))) join `files` on((`files`.`idFile` = `episodeview`.`idFile`))) group by `seasons`.`idSeason`;
and this
Code:
CREATE VIEW `tvshowcounts`
AS SELECT
`tvshow`.`idShow` AS `idShow`,
max(`files`.`lastPlayed`) AS `lastPlayed`,
nullif(count(`episode`.`c12`),0) AS `totalCount`,
count(`files`.`playCount`) AS `watchedcount`,
nullif(count(distinct `episode`.`c12`),0) AS `totalSeasons`,
max(`files`.`dateAdded`) AS `dateAdded` from ((`tvshow` left join `episode` on((`episode`.`idShow` = `tvshow`.`idShow`))) left join `files` on((`files`.`idFile` = `episode`.`idFile`))) group by `tvshow`.`idShow`;
If you have done this open b90(...c90...d90) do the same job again.
I don't need different profiles on the same box. If you want to change profiles on one box use the profile.xml and the userdata folder.