Re: [SlimDevices: Plugins] SQL Playlist - design of database

2010-03-19 Thread PatLogan
Thank you erland, you're gem! Here is my final code: Code: -- PlaylistName:Goldberg Variations -- PlaylistGroups: -- PlaylistOptionDontRepeatTracks:1 -- PlaylistOptionUnlimited:1 select tracks.url from tracks join contributor_track on

Re: [SlimDevices: Plugins] SQL Playlist - design of database

2010-03-18 Thread erland
PatLogan;525917 Wrote: but... I'd like to sort the items by genre. I tried to link the genre tables but did not succeed, if u can help... Cheers :) Pat Try something like this: Code: -- PlaylistName:Goldberg Variations -- PlaylistGroups: select tracks.url

Re: [SlimDevices: Plugins] SQL Playlist - design of database

2010-03-17 Thread PatLogan
Hi erland, thx for your precious help. this works: Code: -- PlaylistName:Goldberg Variations -- PlaylistGroups: select tracks.url from tracks left join dynamicplaylist_history on tracks.id=dynamicplaylist_history.id and

Re: [SlimDevices: Plugins] SQL Playlist - design of database

2010-03-16 Thread erland
I think this is the documentation that exists: http://wiki.slimdevices.com/index.php/SlimServerDatabaseStructure The track name are stored in tracks.title and the track number is stored in tracks.tracknum Your sample doesn't really match your description of what you want to do. Your sample

[SlimDevices: Plugins] SQL Playlist - design of database

2010-03-15 Thread PatLogan
Hi there, Is there the scheme of the database anywhere ? I'd like to customise a query on track name and track number but I don't find how to do this. Here is my example: Code: -- PlaylistName:Goldberg Variations -- PlaylistGroups: select tracks.url from tracks