Help with Video (Episode) Smart Play List
#1
Using 19065 on OS X 10.5.6 with PM.HD

I'm trying to make a smart play list that shows the TV episodes that aired in the last 3 weeks. From the wiki I used this example:

Code:
<smartplaylist type="music">
  <name>Recently Played Songs</name>
  <match>all</match>
  <rule field="lastplayed" operator="inthelast">2 weeks</rule>
  <order direction="descending">lastplayed</order>
</smartplaylist>

My Playlist
Code:
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<smartplaylist type="episodes">
    <name>TV aired in last 3 weeks</name>
    <match>all</match>
    <rule field="airdate" operator="inthelast">3 weeks</rule>
    <order direction="ascending">airdate</order>
</smartplaylist>

In the library if I get info on my recently scanned in shows the air date field is populated. Also the "Recently added playlist" works fine.

Thanks in advance.
Reply
#2
I've updated to the latest stable release, cleaned out my library, settings etc. added one TV show with one episode that aired in the last 2 days and still can't make the smart playlist work.

If I change the type of playlist to "TV Shows" the playlist brings me to the TV show listing page and lists the TV shows that aired.

Is this type of episode playlist just not possible? Thanks for any help.
Reply
#3
Hello,

I have been trying to create a playlist that would allow me to view all of the TV Show episodes that I have downloaded in the last week and have not viewed yet. I have tried the "Aired in" "the last" selections in the playlist and I can't seem to figure out how to make it work. If I put "week" or "1 week" or "7 days", I get shows that have aired well over 7 days or a week ago. Has anyone managed to figure out a way to do this? Could anyone tell me how to go about making this playlist work?

Thanks,
Mark
Reply
#4
hmmm I just tried this too and have a similar issue. I created the following video playlist:

Code:
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<smartplaylist type="episodes">
    <name>Aired in last 2 days</name>
    <match>all</match>
    <rule field="airdate" operator="inthelast">2 days</rule>
</smartplaylist>

Now it takes ages to load - about 20 minutes and then displays pretty much my entire episode library (8000 items). Relevant log section below and full debug here - http://pastebin.com/cKem5wU9

Code:
15:27:13 T:2690020608 M:917467136   DEBUG: SDLKeyboard: scancode: 36, sym: 13, unicode: 13, modifier: 0
15:27:13 T:2690020608 M:917467136   DEBUG: OnKey: 61453 pressed, action is Select
15:27:13 T:2690020608 M:917467136   DEBUG: CGUIMediaWindow::GetDirectory (special://profile/playlists/video/Aired in last 10 days.xsp)
15:27:13 T:2690020608 M:917467136   DEBUG:   ParentPath = [special://videoplaylists/]
15:27:13 T:2690020608 M:917454848   DEBUG: GetEpisodesByWhere query: select * from episodeview WHERE (c05 > '2 days')
15:27:16 T:2690020608 M:901799936   DEBUG: Time for actual SQL query = 2963
15:29:04 T:2690020608 M:875757568   DEBUG: Time to retrieve episodes from dataset = 107712
15:29:04 T:2690020608 M:875544576   DEBUG: Saving fileitems [special://profile/playlists/video/Aired in last 10 days.xsp]
15:29:04 T:2690020608 M:875544576   DEBUG:   -- items: 7877, sort method: 0, ascending: false
15:43:22 T:2953850880 M:810713088   DEBUG: thread start, auto delete: 0
15:43:22 T:2690020608 M:810700800   DEBUG: SDLKeyboard: scancode: 0, sym: 310, unicode: 0, modifier: 0
15:43:22 T:2962022400 M:810405888   DEBUG: Previous line repeats 3 times.
15:43:22 T:2962022400 M:810405888   DEBUG: thread start, auto delete: 1
15:43:22 T:2962022400 M:810405888   DEBUG: DoWork - trying to extract thumb from video file smb://bigbox/tv/Gilmore

Any dev's want to confirm this should work how we expect?
Reply
#5
I brought this up a while ago, never got any responses - still can't get it to work either.

http://forum.xbmc.org/showthread.php?tid=48195
Reply
#6
Thanks guys for confirming this for me. I hope that one of the Dev's can take a look into this issue for us. Sure would like to make it work.

Mark
Reply
#7
I've created a trac ticket for this - http://trac.xbmc.org/ticket/10675

Please feel free to add any useful information you may have to it.
Reply
#8
Just thought I would chime in.

I looked at your error log and noticed the where clause in the database select statement
Code:
GetEpisodesByWhere query: [b]select * from episodeview WHERE (c05 > '2 days')[/b]

Depending on what is stored in the c05 field, I don't think >'2 days' would work because it's trying to filter on the actual string value '2 days', where I would expect the data in the c05 field to be a date. so I would think the statement would read

Code:
GetEpisodesByWhere query: [b]select * from episodeview WHERE (c05 > '11/13/2010')[/b]
--where the date passed is two days ago from today.

I would try and change this to read(I don't know if that syntax is correct)
Code:
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<smartplaylist type="episodes">
    <name>Aired in last 2 days</name>
    <match>all</match>
    <rule field="airdate" operator="inthelast">[b]11/13/2010[/b]</rule>
</smartplaylist>

That should generate the correct select statement, again depending on if a date is stored in the c05 field


This is a snippet from the stock menu showing the submenu item "Recently Added Movies". If we could just replicate that for smart playlist.

Code:
<control type="button" id="90118">
            <include>ButtonHomeSubCommonValues</include>
            <label>$LOCALIZE[31081]</label>
            <onclick>ActivateWindow(VideoLibrary,[b]RecentlyAddedMovies[/b],return)</onclick>
</control>
Reply
#9
In addition to my above post, where are you getting the field "airdate" from? I don't see it in the list of fields from the wiki. Also, how do you know what parameter to pass for the value (string, date, etc..)

Quote:AVAILABLE FIELDS FROM THE :WIKI
album Album the song appears on
artist Artist of the song
albumartist Artist of the album the song appears on
genre Genre of the song
title Title of the song
year Year of the song
tracknumber Track number of the song
time Duration of the song
playcount Number of times the song has been played
filename Filename of the song (excluding path)
lastplayed Date/time of last time the song was played
rating User rating of the song (from 1-5). 0 signifies no rating.
comment Comment tag of the song
playlist Whether the song is in the given playlist
Reply
#10
Hello Th3R00st3r,

Thanks for chiming in. I am not at my HTPC to test your theory on entering a date for use in the "aired in the last" field. I do feel, however, that this is not an option to get the desired results as the date would be constantly changing and would become a PITA to change every day. The playlist should work as prae5 and myself have tried to make it work.
The airdate option, while maybe not in the WIKI is most definately in XBMC itself.

Mark
Reply
#11
mwkurt Wrote:Hello Th3R00st3r,

Thanks for chiming in. I am not at my HTPC to test your theory on entering a date for use in the "aired in the last" field. I do feel, however, that this is not an option to get the desired results as the date would be constantly changing and would become a PITA to change every day. The playlist should work as prae5 and myself have tried to make it work.
The airdate option, while maybe not in the WIKI is most definately in XBMC itself.

Mark

I was only suggesting trying a date instead for testing. I was not implying you hard code the value ;-)

Good to know the Wiki isn't up to date. Would be nice to know what data format was in that c05 field..
Reply
#12
i have now taken care of this. note that the field holds the number of DAYS you want. not a date. since when does 'not in the last 13/11/2010' make sense.. Wink
Reply
#13
This works great now thanks - I made an "Episode" playlist with watched status set to "no" and air date in the last "2 weeks".
Reply
#14
Why can't we order a smartplaylist of tv show episodes by 'first aired'?
Reply
#15
This thread is 4 years old.

There is a good chance that one of the previous posters is now dead.

How about you start a new thread?
Reply

Logout Mark Read Team Forum Stats Members Help
Help with Video (Episode) Smart Play List0