[Bug] TV show seasons are partly wrong
#1
Hi,

I like XBMC and especially the Android remote. Unfortunately there is an error with the TV shows.
I have one TV show with 5 seasons, and all except of the last one are shown as season -1. When I tap on it, there are no episodes in it (which is wrong). The last season, which is shown correctly, has one episode in it and there everything is alright.
I use XBMC r32453 and the newest Remote app from the market. Do you know about this error?
Reply
#2
me too..i have same problem..only in tv shows
Reply
#3
Would you do me a favor? Please run this in the web browser on the machine where the xbmc is running.

Code:
http://localhost:8080/xbmcCmds/xbmcHttp?command=QueryVideoDatabase(SELECT%20tvshow.idShow,%20tvshow.c00%20FROM%20tvshow)
Than right click in the browser and select the "view source" or "view page source" (depends on the browser). And copy what you see into this forum.

It should look something like:

<html>
<field>1</field><field>Fringe</field></html>
Reply
#4
I too have the same problem I installed last night right before bed. I am running xbmc-live so I have no browser on my machine

-=Jason=-
Reply
#5
I have this same or similar problem. I believe it is due to either multiple records of the same show or multiple paths to episodes within the same show.

I believe issue 302 is on the right track. (http://code.google.com/p/android-xbmcrem...ail?id=302)

I ran the query gfoldv suggested, here are my results.

Code:
<html>
<record><field>1</field><field>Weeds</field></record>
<record><field>2</field><field>Upright Citizens Brigade</field></record>
<record><field>3</field><field>The Office (US)</field></record>
<record><field>4</field><field>The Cleveland Show</field></record>
<record><field>5</field><field>Survivorman</field></record>
<record><field>6</field><field>Strangers with Candy</field></record>
<record><field>7</field><field>South Park</field></record>
<record><field>8</field><field>The Sopranos</field></record>
<record><field>9</field><field>The Simpsons</field></record>
<record><field>11</field><field>Lost</field></record>
<record><field>12</field><field>Family Guy</field></record>
<record><field>13</field><field>Everybody Hates Chris</field></record>
<record><field>14</field><field>Entourage</field></record>
<record><field>15</field><field>Curb Your Enthusiasm</field></record>
<record><field>16</field><field>Chappelle's Show</field></record>
<record><field>17</field><field>Battlestar Galactica (2003)</field></record>
<record><field>19</field><field>FlashForward</field></record>
<record><field>20</field><field>Saturday Night Live</field></record>
<record><field>21</field><field>National Geographic Doku</field></record>
<record><field>22</field><field>Dexter</field></record>
<record><field>24</field><field>The Power Of Nightmares</field></record>
<record><field>25</field><field>The life of Buddha</field></record>
<record><field>26</field><field>American Dad!</field></record>
<record><field>27</field><field>The Awful Truth</field></record>
<record><field>28</field><field>Family Guy</field></record>
<record><field>29</field><field>South Park</field></record>
<record><field>30</field><field>Family Guy</field></record>
<record><field>31</field><field>South Park</field></record>
<record><field>32</field><field>The Daily Show: Global Edition</field></record>
<record><field>33</field><field>Entourage</field></record>
<record><field>34</field><field>My Name Is Earl</field></record>
<record><field>35</field><field>The Colbert Report</field></record>
</html>

HTH
Reply
#6
wankdanker, thank you for the html result. From this list for which show do you get the faulty -1 for the seasons?
Reply
#7
Here is what I see where there are issues. When I refer to 'Banner' I am talking about the graphic that is displayed for the show.

Entourage - Banner
Entourage - No Banner, 55 Episodes
Entourage - No Banner, -1 Episodes

Family Guy - Banner
Family Guy - No Banner, -1 Episodes
Family Guy - No Banner, 11 Episodes
Family Guy - No Banner, -1 Episodes

South Park - Banner
South Park - No Banner, 5 Episodes
South Park - No Banner, -1 Episodes


Thanks gfoldv!
Reply
#8
So you get -1 only for that shows which have multiple record, don't you?
Reply
#9
Yes, and I can see how this is happening too.

Here is the query that is executed to get the list of shows:

Code:
SELECT tvshow.idShow, tvshow.c00, "" AS c01, ROUND(tvshow.c04, 2), tvshow.c05, tvshow.c08, tvshow.c13, tvshow.c14,
   path.strPath AS strPath,
   counts.totalcount AS totalCount,
   counts.watchedcount AS watchedCount,
   counts.totalcount = counts.watchedcount AS watched
FROM tvshow
JOIN tvshowlinkpath ON tvshow.idShow = tvshowlinkpath.idShow
JOIN path ON path.idpath = tvshowlinkpath.idPath
LEFT OUTER join (
    SELECT tvshow.idShow AS idShow, count(1) AS totalcount, count(files.playCount) AS watchedcount
    FROM tvshow
    JOIN tvshowlinkepisode ON tvshow.idShow = tvshowlinkepisode.idShow
    JOIN episode ON episode.idEpisode = tvshowlinkepisode.idEpisode
    JOIN files ON files.idFile = episode.idFile
    GROUP BY tvshow.idShow
)
counts ON tvshow.idShow = counts.idShow
ORDER BY upper(tvshow.c00), tvshow.c00

I ran this query using sqlite3 cli directly on MyVideos database. Since the first table in the query is tvshow and it contains multiple records for the same show it will have a record for each instance in the result set. If there happens to be any files linking to that specific record, then the counts will be included from the LEFT OUTER JOIN. The cases where I see a -1 in the remote control interface are when there are no actual files for that show in which case totalCount and watchedCount would end up being null.

I tried the following query and it returns everything as expected:

Code:
SELECT tvshow.idShow, tvshow.c00, "" AS c01, ROUND(tvshow.c04, 2), tvshow.c05, tvshow.c08, tvshow.c13, tvshow.c14,
    paths.strPath,
    counts.totalcount AS totalCount,
    counts.watchedcount AS watchedCount,
    counts.totalcount = counts.watchedcount AS watched
  FROM (
    select min(tvshow.idShow) as idShow, tvshow.c00 from tvshow
    group by tvshow.c00
  ) showNames
  LEFT OUTER join tvshow on showNames.idShow = tvshow.idShow
  LEFT OUTER join (
     SELECT min(tvshow.idShow) as idShow, tvshow.c00, count(1) AS totalcount, count(files.playCount) AS watchedcount
     FROM tvshow
     JOIN tvshowlinkepisode ON tvshow.idShow = tvshowlinkepisode.idShow
     JOIN episode ON episode.idEpisode = tvshowlinkepisode.idEpisode
     JOIN files ON files.idFile = episode.idFile
     GROUP BY tvshow.c00
  ) counts ON tvshow.idShow = counts.idShow
  LEFT OUTER join (
     SELECT tvShow.idShow, strPath
     FROM tvshow
     JOIN tvshowlinkpath ON tvshow.idShow = tvshowlinkpath.idShow
     JOIN path ON path.idpath = tvshowlinkpath.idPath
     WHERE path.idPath in (SELECT max(idPath) FROM tvshowlinkpath GROUP BY idShow)
  )  paths on tvshow.idShow = paths.idShow
ORDER BY upper(tvshow.c00), tvshow.c00
Reply
#10
After reviewing the OP's message, I think that the issue I am having is different from what they described. However I think the issue that I am describing would lead to the solution for all of these issues. I am going to work on getting the source and attempt to provide a patch for these queries. Good thing my boss isn't working today. Smile
Reply
#11
Quote: Would you do me a favor? Please run this in the web browser on the machine where the xbmc is running.

Code:

http://localhost:8080/xbmcCmds/xbmcHttp?...M%20tvshow)

Than right click in the browser and select the "view source" or "view page source" (depends on the browser). And copy what you see into this forum.

It should look something like:

<html>
<field>1</field><field>Fringe</field></html>


Sorry for answering so late, I did not expect to get so many replies in such a short time Shocked
Here is the code I get:
Code:
<html>
<field>2</field><field>Alarm für Cobra 11 - Die Autobahnpolizei</field><field>3</field><field>Navy CIS</field><field>4</field><field>The Mentalist</field><field>6</field><field>Es war einmal... Das Leben</field><field>7</field><field>MythBusters - Die Wissensjäger</field><field>8</field><field>Stromberg</field>
</html>

I also just noticed that this problem only appears if there are more than one seasons belonging to a tv show. It would be really great if you can fix this.
Reply
#12
Will check out your patch in a minute wankdanker. Sorry it took so long, I'm more outside that behind the screen in my freetime these days.
Running XBMC on my HTPC, tablet, phone and pinball machine.
Always read the XBMC online-manual, FAQ and search the forums before posting. Do NOT e-mail Team-XBMC members asking for support. For troubleshooting and bug reporting, make sure you read this first.
Reply
#13
Thanks freezy. No problem. Gotta enjoy the summer while it's around. Smile

If you need anything more from the patch like comments or whatever, just let me know. I'm more than happy to do whatever I can for the project.
Reply
#14
Test it! Smile
Here is an intermediate build.

Cheers!
Running XBMC on my HTPC, tablet, phone and pinball machine.
Always read the XBMC online-manual, FAQ and search the forums before posting. Do NOT e-mail Team-XBMC members asking for support. For troubleshooting and bug reporting, make sure you read this first.
Reply
#15
Hi guys,

I had an issue where my TV Shows would show up on the remote multiple times, in addition to the bug mentioned in this thread.

My 'TV Shows' source is linked to multiple folders, and sometimes certain shows are spanned among those folders.

Example:

Source setup:
TV Shows
{
C:\Video\TV Shows,
D:\Video (overflow)\TV Shows,
E:\Video (overflow 2)\TV Shows,
F:\Video (overflow 3)\TV Shows
}

Spanned TV Show:
Futurama Season 1-4 may be in the C: "TV Shows" folder
Futurama Season 5 in the D: "TV Shows" folder
Futurama Season 6 in the F: "TV Shows" folder

In XBMC this spanning is completely transparent. In the version of the remote that is on the market (as of this post) there was the problem I mentioned.

ANYWAY... the intermediate build solved the issue for me BUT the back button on my phone has to be held now in order to flip back a screen. I'm sure you're already aware, but if not, then now you are Smile

I just wanted to let you know. Keep up the good work!
Reply

Logout Mark Read Team Forum Stats Members Help
[Bug] TV show seasons are partly wrong0