Smart playlist for local file probs.
#1
I've been using smart playlsits off net shares for a number of years, no probs at all.

I've recently moved some content to a local disk on the MC and can't get the local playlist to work and would be grateful for any tips...!

Files are on local disk, they have been scraped and added to the library, I can browse to them through videos... files... source... and have full metadata and no probs playing.

Here's source and playlist for a net share source that works fine:

Code:
<source>
            <name>[Unwatched]</name>
            <path pathversion="1">smb://Server/Movies/[Unwatched]/</path>
</source>

Code:
<smartplaylist type="movies">
    <name>Unwatched</name>
    <match>all</match>
    <rule field="path" operator="contains">smb://Server/Movies/[Unwatched]/</rule>
</smartplaylist>

Then I create a new playlist in the UI, file gets generated ok but playlist has zero content:

Code:
<source>
            <name>[Oldies]</name>
            <path pathversion="1">G:\Oldies\</path>
        </source>

Code:
<smartplaylist type="movies">
    <name>OldFilms</name>
    <match>all</match>
    <rule field="path" operator="contains">
        <value>G:\Oldies\</value>
    </rule>
</smartplaylist>

The format is slightly different with the value wrapped in value tags but even using the same format as the working one, I can't get the playlist to show any content.
I know I'll be missing something simple but any clues...? Big Grin
Reply
#2
watch for / and \
Reply
#3
Thanks for the reply but that didn't work.

The \ in place is from the GUI generated xsp file so would be disappointed if it was creating the wrong syntax.

Can anyone paste in an example of a working local path based playlist?
Reply
#4
Here's the string from the debug log that's used when the playlist is selected:

Code:
DEBUG: CVideoDatabase::RunQuery took 4 ms for 0 items query: select * from movieview  WHERE ((movieview.strPath LIKE '%G:\\Oldies\\%'))

If I run that query direct, I get no results.
But if I play with the serach string, I can get results returned as shown below:

Image

Searching just G: returns all the movies on G: (line 1)
G: with 2 backslashes (one as escape), no results (line 3)
G: with 3 backslashes, all movies on G: (line 4)
"Oldies" = all the movies in the oldies folder. (line 5)
Building a combination to find a string that works = beyond my capabilities Big Grin
Reply
#5
Does this work ?

PHP Code:
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<smartplaylist type="movies">
    <name>Oldies</name>
    <match>all</match>
    <rule field="path" operator="contains">
        <value>Oldies</value>
    </rule>
    <order direction="ascending">sorttitle</order>
</smartplaylist> 
Learning Linux the hard way !!
Reply
#6
Thanks yes (like line 5 in the screenshot above), but I'd like it to be specific full path as some of my setup has similar folder names on different paths.

Looks like it's the backslashes are causing the issues.
Reply

Logout Mark Read Team Forum Stats Members Help
Smart playlist for local file probs.0