Home of the Squeezebox™ & Transporter® network music players.
Page 2 of 2 FirstFirst 12
Results 11 to 19 of 19
  1. #11
    Senior Member
    Join Date
    Jul 2010
    Location
    Oz
    Posts
    361
    Quote Originally Posted by PasTim View Post
    I'm struggling with the complexity of the FAQs. There are so many features I've never heard of, and some terms that evade me, but I'll try.
    I'm quite confident that you will succeed. Don't worry too much about terms and new features. At the core DPL is still just a means to serve you those tracks that you select with your SQLite code/dynamic playlist.

    Try this: save the SQLite code of your dynamic playlists (just like the examples you posted here) as plain text files, change the file extension to .sql.xml and move these files to DPL's folder for custom dynamic playlists called DPL-custom-lists (default location of that folder: in your LMS playlist folder). Uninstall DPL2 and install DPL3. Maybe uninstall SQLPlayList for the time being. Your custom dynamic playlists should show up now. Your SQLPlayLists playlists and DPL2 preferences will still be there when you uninstall DPL3 and reinstall DPL2 and SQLPlayList.

    If you want unlimited tracks and non-random order replace -- PlaylistOption Unlimited:1 (from your first example) with these 2 lines:
    Code:
    -- PlaylistLimitOption:unlimited
    -- PlaylistTrackOrder:ordered
    Can you post the SQLite code of your MultiLibraries from the MultiLibraries plugin? (not the dynamic playlists) The more the better. That would give me a better idea of whether and how your MultiLibraries can be recreated as virtual libraries.
    Plugin repositories: Ratings Light •••• Visual Statistics •••• Use Comment Tag Info •••• Dynamic Playlists 3 FAQ •••• Custom Skip 3 FAQ

  2. #12
    Senior Member
    Join Date
    Nov 2010
    Location
    Hertfordshire, UK
    Posts
    3,275
    Quote Originally Posted by afriend View Post
    I'm quite confident that you will succeed. Don't worry too much about terms and new features. At the core DPL is still just a means to serve you those tracks that you select with your SQLite code/dynamic playlist.

    Try this: save the SQLite code of your dynamic playlists (just like the examples you posted here) as plain text files, change the file extension to .sql.xml and move these files to DPL's folder for custom dynamic playlists called DPL-custom-lists (default location of that folder: in your LMS playlist folder). Uninstall DPL2 and install DPL3. Maybe uninstall SQLPlayList for the time being. Your custom dynamic playlists should show up now. Your SQLPlayLists playlists and DPL2 preferences will still be there when you uninstall DPL3 and reinstall DPL2 and SQLPlayList.
    MY dynamic playlists already have extension .sql.xml, so I don't understand what you are asking me to do. By the way, what do [B] etc mean?

    If you want unlimited tracks and non-random order replace -- PlaylistOption Unlimited:1 (from your first example) with these 2 lines:
    Code:
    -- PlaylistLimitOption:unlimited
    -- PlaylistTrackOrder:ordered
    All my Dynamic playlists are random, so I guess I stay with PlaylistLimitOption:unlimited
    Can you post the SQLite code of your MultiLibraries from the MultiLibraries plugin? (not the dynamic playlists) The more the better. That would give me a better idea of whether and how your MultiLibraries can be recreated as virtual libraries.[/QUOTE]
    I don't know where all the sql resides. The section defined when the user creates a library is xml like this:
    Code:
    <?xml version="1.0" encoding="utf-8"?>
    <multilibrary>
    	<template>
    		<id>standard.xml</id>
    		<parameter type="text" id="libraryname"><value>Classical Music</value></parameter>
    		<parameter type="text" id="libraryorder"><value>50</value></parameter>
    		<parameter type="text" id="menugroup"></parameter>
    		<parameter type="text" id="directory1"></parameter>
    		<parameter type="text" id="directory2"></parameter>
    		<parameter type="text" id="directory3"></parameter>
    		<parameter type="text" id="directory4"></parameter>
    		<parameter type="text" id="excludedirectory1"></parameter>
    		<parameter type="text" id="excludedirectory2"></parameter>
    		<parameter type="text" id="excludedirectory3"></parameter>
    		<parameter type="text" id="excludedirectory4"></parameter>
    		<parameter type="text" id="playlist"><value></value></parameter>
    		<parameter type="text" id="containsincludedcomment"><value>0</value></parameter>
    		<parameter type="text" id="includedcomment"></parameter>
    		<parameter type="text" id="containsexcludedcomment"><value>0</value></parameter>
    		<parameter type="text" id="excludedcomment"></parameter>
    		<parameter type="text" id="includedgenres" quotevalue="1"><value>Classical</value></parameter>
    		<parameter type="text" id="excludedgenres" quotevalue="1"></parameter>
    		<parameter type="text" id="includedartists" quotevalue="1"></parameter>
    		<parameter type="text" id="excludedartists" quotevalue="1"></parameter>
    		<parameter type="text" id="lossless"><value>0</value></parameter>
    		<parameter type="text" id="lossy"><value>0</value></parameter>
    		<parameter type="text" id="minbitrate"></parameter>
    		<parameter type="text" id="maxbitrate"></parameter>
    		<parameter type="text" id="includedcontenttypes" quotevalue="1"></parameter>
    		<parameter type="text" id="includedclients"></parameter>
    		<parameter type="text" id="excludedclients"></parameter>
    		<parameter type="text" id="internalmenus"></parameter>
    		<parameter type="text" id="custombrowsemenus"></parameter>
    		<parameter type="text" id="enabledbrowse"><value>0</value></parameter>
    	</template>
    </multilibrary>
    The plugin has an sql folder containing:
    Code:
    CREATE TABLE multilibrary_genre (
      library int(10) not null,
      genre int(10) not null,
      primary key (library,genre)
    );
    
    CREATE TABLE multilibrary_year (
      library int(10) not null,
      year int(10) not null,
      primary key (library,year)
    );
    
    CREATE TABLE multilibrary_contributor (
      library int(10) not null,
      contributor int(10) not null,
      primary key (library,contributor)
    );
    
    CREATE TABLE multilibrary_album (
      library int(10) not null,
      album int(10) not null,
      primary key (library,album)
    );
    
    CREATE TABLE multilibrary_track (
      library int(10) not null,
      track int(10) not null,
      primary key (library,track)
    );
    
    CREATE TABLE multilibrary_libraries (
      id INTEGER PRIMARY KEY AUTOINCREMENT,
      libraryid varchar(255) not null,
      name varchar(255) not null
    );
    LMS 8.1 on PC, Xubuntu 20.04, FLACs 16->24 bit, 44.1->192kbps. 2 Touches & EDO.
    LMS plugin UPnP/DLNA Bridge to MF M1 CLiC (A308CR amp & ESLs) & Marantz CR603 UPnP renderers.
    Also Minimserver & Upplay to same & to upmpdcli/mpd PC renderers.
    Squeezelite to Meridian USB Explorer DAC to PC speakers/headphones.
    Wireless Xubuntu 20.04 laptop firefox/upplay or Android mobile with Squeeze-Ctrl/BubbleUPnP controls LMS/Minimserver.

  3. #13
    Senior Member
    Join Date
    Jul 2010
    Location
    Oz
    Posts
    361
    Quote Originally Posted by PasTim View Post
    MY dynamic playlists already have extension .sql.xml, so I don't understand what you are asking me to do.
    Ok then. I thought you were using SQLPlayList to get your custom dynamic playlists into DPL - which is no longer necessary/recommended with DPL3. What I described was how to use your custom dyn. playlists with DPL3 without SQLPlayList. More detailled information on the relation between DPL and SQLPlayList, and on how to create/import your custom dyn. playlists into DPL3 can be found in the FAQ.

    Quote Originally Posted by PasTim View Post
    By the way, what do [B] etc mean?
    ?? Are you talking about the styling tags in this forum (B = bold)?

    Quote Originally Posted by PasTim View Post
    All my Dynamic playlists are random, so I guess I stay with PlaylistLimitOption:unlimited
    Misunderstanding. Take your first example Random Classical Top Rated Works. You pick a random work with rating 80+ but then you do want to play this work's movements in non-random order, no?
    That's what the PlaylistTrackOrder parameter is for because DPL3 adds extra randomness/shuffling to tracks unless you use this line. It's just a way to disable this extra shuffling.

    As for Multilibraries, what you posted was the .sql.values.xml content, just the values that ML parses to create valid SQLite queries. But that's ok.

    How many Multilibraries do you have?
    And can you describe the criteria you use to create your Mulltilibraries?
    Are they basically supposed to filter by genre (Classical or Non-Classical)?
    I'd be especially interested in your more complex Multilibraries.

    BTW you can see the actual SQLite code of each library in the Multilibraries web UI if you edit them and then at the bottom choose Customize SQL, then click Next. There you can see/copy the actual SQLite code. But don't click save afterwards.
    Plugin repositories: Ratings Light •••• Visual Statistics •••• Use Comment Tag Info •••• Dynamic Playlists 3 FAQ •••• Custom Skip 3 FAQ

  4. #14
    Senior Member
    Join Date
    Nov 2010
    Location
    Hertfordshire, UK
    Posts
    3,275
    Quote Originally Posted by afriend View Post
    Ok then. I thought you were using SQLPlayList to get your custom dynamic playlists into DPL - which is no longer necessary/recommended with DPL3. What I described was how to use your custom dyn. playlists with DPL3 without SQLPlayList. More detailled information on the relation between DPL and SQLPlayList, and on how to create/import your custom dyn. playlists into DPL3 can be found in the FAQ.
    Now I'm confused. I'll have to try the FAQ again, but I think the short version is that I only have to move my existing files to another folder, maybe with a first line edit on some.
    ?? Are you talking about the styling tags in this forum (B = bold)?
    Yes, but since I'm so often reading your text as a quote, the styling tags don't work there - sorry - my confusion.

    Misunderstanding. Take your first example Random Classical Top Rated Works. You pick a random work with rating 80+ but then you do want to play this work's movements in non-random order, no?
    That's what the PlaylistTrackOrder parameter is for because DPL3 adds extra randomness/shuffling to tracks unless you use this line. It's just a way to disable this extra shuffling.
    That's what I though (I think....)
    As for Multilibraries, what you posted was the .sql.values.xml content, just the values that ML parses to create valid SQLite queries. But that's ok.

    How many Multilibraries do you have?
    And can you describe the criteria you use to create your Mulltilibraries?
    Are they basically supposed to filter by genre (Classical or Non-Classical)?
    I'd be especially interested in your more complex Multilibraries.

    BTW you can see the actual SQLite code of each library in the Multilibraries web UI if you edit them and then at the bottom choose Customize SQL, then click Next. There you can see/copy the actual SQLite code. But don't click save afterwards.
    I don't want to waste your time on multilibrary. That would be a much bigger change for me, including almost all my menus. I only use it to separate classical from the rest, since I use different tagging and playing rules. Further, without customscan to get my classical and other tags, multilibrary wouldn't help me much. If I ever decide to review all that I'll start some other thread, but it's quite likely that I'd just have to freeze LMS at a working point, never update again, and cross my fingers. I might even have to move off LMS to something like minimserver.
    LMS 8.1 on PC, Xubuntu 20.04, FLACs 16->24 bit, 44.1->192kbps. 2 Touches & EDO.
    LMS plugin UPnP/DLNA Bridge to MF M1 CLiC (A308CR amp & ESLs) & Marantz CR603 UPnP renderers.
    Also Minimserver & Upplay to same & to upmpdcli/mpd PC renderers.
    Squeezelite to Meridian USB Explorer DAC to PC speakers/headphones.
    Wireless Xubuntu 20.04 laptop firefox/upplay or Android mobile with Squeeze-Ctrl/BubbleUPnP controls LMS/Minimserver.

  5. #15
    Senior Member
    Join Date
    Nov 2010
    Location
    Hertfordshire, UK
    Posts
    3,275
    afriend - just to say I've got started, and several of my main random lists are working OK now that I've sorted out the 'ordered' issue and the related DPL setting.

    Thanks for your patience and help.

    If I get any insurmountable problems I'll post back here.
    LMS 8.1 on PC, Xubuntu 20.04, FLACs 16->24 bit, 44.1->192kbps. 2 Touches & EDO.
    LMS plugin UPnP/DLNA Bridge to MF M1 CLiC (A308CR amp & ESLs) & Marantz CR603 UPnP renderers.
    Also Minimserver & Upplay to same & to upmpdcli/mpd PC renderers.
    Squeezelite to Meridian USB Explorer DAC to PC speakers/headphones.
    Wireless Xubuntu 20.04 laptop firefox/upplay or Android mobile with Squeeze-Ctrl/BubbleUPnP controls LMS/Minimserver.

  6. #16
    Senior Member
    Join Date
    Nov 2010
    Location
    Hertfordshire, UK
    Posts
    3,275
    Hi afriend.

    I have managed to create a library view setup for my music, which matches my old multilibraries setup. To get it to work well with my own normal menus I had to create an additional table which maps the 8 character code for the library to the name of the library (as defined in the prefs file). That works, so far so good.

    In some of my DPLs this also works well, using the PlaylistVirtualLibraryName1 parameter in my sql, rather than my own extra table.

    However, if I want to select a subset at run-time, say for a set of genres in that library, defining a PlaylistParameter1, this doesn't seem to work with a PlaylistVirtualLibraryName1 defined previously, presumably because the definitions aren't all available to the other definitions until the main select starts.

    If you agree that this is a feature, could it be overcome?
    LMS 8.1 on PC, Xubuntu 20.04, FLACs 16->24 bit, 44.1->192kbps. 2 Touches & EDO.
    LMS plugin UPnP/DLNA Bridge to MF M1 CLiC (A308CR amp & ESLs) & Marantz CR603 UPnP renderers.
    Also Minimserver & Upplay to same & to upmpdcli/mpd PC renderers.
    Squeezelite to Meridian USB Explorer DAC to PC speakers/headphones.
    Wireless Xubuntu 20.04 laptop firefox/upplay or Android mobile with Squeeze-Ctrl/BubbleUPnP controls LMS/Minimserver.

  7. #17
    Senior Member
    Join Date
    Jul 2010
    Location
    Oz
    Posts
    361
    Quote Originally Posted by PasTim View Post
    To get it to work well with my own normal menus I had to create an additional table which maps the 8 character code for the library to the name of the library (as defined in the prefs file).
    Nothing to do with DPL but just out of curiosity: your table serves just this one purpose: to provide a name for your VLibs? Did you write a plugin that creates your "own normal" menus based on that? Are we talking complicated (multi-level nestedCustom menus or just run-of-the-mill LMS menus like all kinds of contributor menus, albums, genres...

    Quote Originally Posted by PasTim View Post
    if I want to select a subset at run-time, say for a set of genres in that library, defining a PlaylistParameter1, this doesn't seem to work with a PlaylistVirtualLibraryName1 defined previously, presumably because the definitions aren't all available to the other definitions until the main select starts.
    I'm not sure I understand what you're trying to do here. Can you post a dynamic playlist example with detailled comments to illustrate what you're trying to achieve?
    Plugin repositories: Ratings Light •••• Visual Statistics •••• Use Comment Tag Info •••• Dynamic Playlists 3 FAQ •••• Custom Skip 3 FAQ

  8. #18
    Senior Member
    Join Date
    Nov 2010
    Location
    Hertfordshire, UK
    Posts
    3,275
    Quote Originally Posted by AF1 View Post
    Nothing to do with DPL but just out of curiosity: your table serves just this one purpose: to provide a name for your VLibs? Did you write a plugin that creates your "own normal" menus based on that? Are we talking complicated (multi-level nestedCustom menus or just run-of-the-mill LMS menus like all kinds of contributor menus, albums, genres...
    Yes, just the one purpose. I just populate it using SQL, copying the numbers from the library prefs. That way, if I have have to start again from scratch, and the codes change, it's easy for me to just change the one table entries rather than edit all my menus. I use it mainly to split Classical music (with an array of essential additional tags required to select and play it properly) from other types of music, and intend to maybe do a bit more once I'm happy I've got it working for all my main purposes. I used to be a programmer, but my coding days are mostly long gone. It would take me forever to find out how to create a plugin for LMS, let alone get access to the prefs table directly, and somehow use that in my Custom Browse menus. Using just SQL is simpler, and, I hope, more reliable long term in terms of compatibilty.

    I'm not sure I understand what you're trying to do here. Can you post a dynamic playlist example with detailled comments to illustrate what you're trying to achieve?
    Simply select a subset of items at the start of a DPL menu, where the subset belongs to a partiocular library, so:
    Code:
    -- PlaylistName:Rated songs in classical genre
    -- PlaylistGroups:Random/For selected
    -- PlaylistTrackOrder:ordered
    -- PlaylistLimitOption:unlimited
    -- PlaylistVirtualLibraryName1:Classical
    -- PlaylistParameter1:customgenre:Select genre:select id,name,substr(namesort,1,1) from genres join library_libraries on library_genre.library=library_libraries.library and library_libraries.library_name='Classical' join library_genre on genres.id=library_genre.genre order by genres.namesort
    select url from
    	(select tracks.url from tracks join library_track on
            library_track.track = tracks.id and library_track.library = 'PlaylistVirtualLibraryName1'
            join genre_track on
    			tracks.id=genre_track.track and
    			genre_track.genre='PlaylistParameter1'
    		join track_statistics on
    			tracks.url=track_statistics.url
    		left join dynamicplaylist_history on
    			tracks.id=dynamicplaylist_history.id and dynamicplaylist_history.client='PlaylistPlayer'
    		where
    			audio=1
    			and track_statistics.rating>=70
    			and dynamicplaylist_history.id is null
    		group by tracks.id
    		order by random()
    		
    		limit 100) as rated
    	order by random();
    I can 't use PlaylistVirtualLibraryName1 in the initial genre selection, so I had to use my new table to do it instead.
    Note that my tracks can have multiple genres, so the Classical genres has many sub-genres, and in this case I don't want to see loads of other non-Classical genres in my selection.

    I am sure there are there are several other ways of doing this, and it's not a problem, more of a 'neatness' question.
    LMS 8.1 on PC, Xubuntu 20.04, FLACs 16->24 bit, 44.1->192kbps. 2 Touches & EDO.
    LMS plugin UPnP/DLNA Bridge to MF M1 CLiC (A308CR amp & ESLs) & Marantz CR603 UPnP renderers.
    Also Minimserver & Upplay to same & to upmpdcli/mpd PC renderers.
    Squeezelite to Meridian USB Explorer DAC to PC speakers/headphones.
    Wireless Xubuntu 20.04 laptop firefox/upplay or Android mobile with Squeeze-Ctrl/BubbleUPnP controls LMS/Minimserver.

  9. #19
    Senior Member
    Join Date
    Jul 2010
    Location
    Oz
    Posts
    361
    Quote Originally Posted by PasTim View Post
    Code:
    -- PlaylistName:Rated songs in classical genre
    -- PlaylistGroups:Random/For selected
    -- PlaylistTrackOrder:ordered
    -- PlaylistLimitOption:unlimited
    -- PlaylistVirtualLibraryName1:Classical
    -- PlaylistParameter1:customgenre:Select genre:select id,name,substr(namesort,1,1) from genres join library_libraries on library_genre.library=library_libraries.library and library_libraries.library_name='Classical' join library_genre on genres.id=library_genre.genre order by genres.namesort
    select url from
    	(select tracks.url from tracks join library_track on
            library_track.track = tracks.id and library_track.library = 'PlaylistVirtualLibraryName1'
            join genre_track on
    			tracks.id=genre_track.track and
    			genre_track.genre='PlaylistParameter1'
    		join track_statistics on
    			tracks.url=track_statistics.url
    		left join dynamicplaylist_history on
    			tracks.id=dynamicplaylist_history.id and dynamicplaylist_history.client='PlaylistPlayer'
    		where
    			audio=1
    			and track_statistics.rating>=70
    			and dynamicplaylist_history.id is null
    		group by tracks.id
    		order by random()
    		
    		limit 100) as rated
    	order by random();
    I can 't use PlaylistVirtualLibraryName1 in the initial genre selection, so I had to use my new table to do it instead.
    Note that my tracks can have multiple genres, so the Classical genres has many sub-genres, and in this case I don't want to see loads of other non-Classical genres in my selection.
    I am sure there are there are several other ways of doing this, and it's not a problem, more of a 'neatness' question.
    You're right. DPL asks for playlist parameter input when you start a dynamic playlist and the parameters don't know about each other.
    For your use case I recommend this: DPL does actually check if there's an active library view/virtual library set for the player that's starting the dynamic playlist (it's client-specific).
    So set the virtual library with all your classical music as the active library view/virtual library for your player and then adapt your dynamic playlist or maybe try this one:

    Code:
    -- PlaylistName:Rated songs in classical genre
    -- PlaylistGroups:Random/For selected
    -- PlaylistLimitOption:unlimited
    -- PlaylistParameter1:multiplegenres:Select genres:
    select tracks.url from tracks
    	join library_track on
    		library_track.track = tracks.id and library_track.library = 'PlaylistCurrentVirtualLibraryForClient'
    	join genre_track on
    		genre_track.track = tracks.id and genre_track.genre in ('PlaylistParameter1')
    	join tracks_persistent on
    		tracks_persistent.urlmd5 = tracks.urlmd5
    	left join dynamicplaylist_history on
    		tracks.id=dynamicplaylist_history.id and dynamicplaylist_history.client='PlaylistPlayer'
    	where
    		audio=1
    		and tracks_persistent.rating>=70
    		and dynamicplaylist_history.id is null
    	group by tracks.id
    	order by random()
    	limit 100;
    Please note that this dynamic playlist will not work if you haven't set a library view/virtual library for your player.
    Your own playlist example calls random() 2 times. No need: just lose the PlaylistTrackOrder parameter (that's for when you don't want any randomization at all: listening to complete albums, movements...) and DPL will add extra randomization.


    Quote Originally Posted by PasTim View Post
    Yes, just the one purpose. I just populate it using SQL, copying the numbers from the library prefs. ... and somehow use that in my Custom Browse menus.
    So I don't know how exactly you use your virtual libraries table with CustomBrowse. But since you're obviously comfortable with SQLite I remembered that I once had a small plugin that used custom SQLite definitions to create virtual libraries. It kind of was the predecessor of the more specific UseCommentTagInfo plugin. I've found a copy of SQLiteVirtualLibraries in my backups and uploaded it to GitHub. Maybe check it out to see if it's of any interest to you.
    Plugin repositories: Ratings Light •••• Visual Statistics •••• Use Comment Tag Info •••• Dynamic Playlists 3 FAQ •••• Custom Skip 3 FAQ

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •