DynamicPlayList stopped working after upgrade to 7.6

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Tony T
    Senior Member
    • Nov 2009
    • 1469

    DynamicPlayList stopped working after upgrade to 7.6

    Just d/l's SBS 7.6 and Dynamic Playlists no longer works.

    Here's a sample log:


    [11-07-26 22:00:11.6742] Plugins::SQLPlayList::Plugin::executeSQLForPlaylis t (1036) Database error: no such function: rand
    Carp::Clan::__ANON__(): DBI Exception: DBD::SQLite::db prepare failed: no such function: rand [for Statement "select tracks.url from tracks join track_statistics on tracks.url=track_statistics.url where audio=1 and (ifnull(track_statistics.rating,0)=0 or track_statistics.rating>=30) and not exists (select * from tracks t2,genre_track,genres where t2.id=tracks.id and tracks.id=genre_track.track and genre_track.genre=genres.id and genres.name in ('Comedy')) and ifnull(track_statistics.playcount,0)=0 group by tracks.id order by rand() limit 10;"] at /Library/PreferencePanes/Squeezebox.prefPane/Contents/server/Slim/Schema/Storage.pm line 123
    Tony
     SBTouch ♪ SBRadio ♬
  • aubuti
    Senior Member
    • Oct 2005
    • 8889

    #2
    Forgive the obvious question, but did you update the Dynamic Playlist plugin as well? Also check to see if you need to update SQLPlaylist plugin.
    Main system: SB3 > Emotiva XDA-1 > NAD C 325BEE > Vandersteen 1
    Living room: SB2 > Audioengine HD6
    Kitchen/dining: SB2 > AudioSource AMP 100 > 2-pairs of Polk Audio RC60i in-ceiling speakers
    Deck/patio: SB Receiver > AudioSource AMP 100 > Polk Atrium 45
    Study: Squeezelite-X on Win10 laptop with cheapo Logitech speakers
    Bedroom: SB Radio
    Quiet time: Hifiman Sundara headphones plugged into NAD amp or iPhone + AudioQuest Dragonfly Red DAC/amp
    LMS 8.5 running on a Raspberry Pi3 (piCore), controlled using iPeng and SB Controllers

    Comment

    • erland
      Senior Member
      • Jan 2006
      • 11323

      #3
      If you have customized the SQL yourself, you need to change "rand" to "random".

      If you haven't customized the SQL and sees the more user friendly view when editing the SQL playlist, it should handle it automatically as long as you have the latest version of Dynamic Playlists and SQL Playlists plugins.

      If you don't get it to work, please let me know which playlist template the playlist is based on because then I might have missed something.
      Erland Lindmark (My homepage)
      Developer of many plugins/applets
      Starting with LMS 8.0 I no longer support my plugins/applets (see here for more information )

      Comment

      • Tony T
        Senior Member
        • Nov 2009
        • 1469

        #4
        Originally posted by erland
        If you have customized the SQL yourself, you need to change "rand" to "random".

        If you haven't customized the SQL and sees the more user friendly view when editing the SQL playlist, it should handle it automatically as long as you have the latest version of Dynamic Playlists and SQL Playlists plugins.

        If you don't get it to work, please let me know which playlist template the playlist is based on because then I might have missed something.
        I have Dynamic Playlist v2.8.4 and SQL Playlist v2.5.3359
        I'm using the 'user friendly version', and also none of the pre-set templates in SQL Playlist work either.

        Here's one of the templates:
        Code:
        -- PlaylistName:Random songs
        -- PlaylistGroups:Random
        -- PlaylistStartAction1:cli:customskip setsecondaryfilter recentlyaddedartistfilterset.cs.xml
        -- PlaylistStopAction1:cli:customskip clearsecondaryfilter
        select tracks.url from tracks
        	join track_statistics on
        		tracks.url=track_statistics.url
        	where
        		audio=1
        		and (ifnull(track_statistics.rating,0)=0 or track_statistics.rating>=30)
        		and not exists (select * from tracks t2,genre_track,genres
        						where
        							t2.id=tracks.id and
        							tracks.id=genre_track.track and 
        							genre_track.genre=genres.id and
        							genres.name in ('Comedy'))
        		and ifnull(track_statistics.playcount,0)=0
        	group by tracks.id
        	order by random()
        	limit 10;
        Tony
         SBTouch ♪ SBRadio ♬

        Comment

        • erland
          Senior Member
          • Jan 2006
          • 11323

          #5
          Doesn't this one work ?

          The difference is that in 7.5, the SQL had to say:
          order by rand()

          But in 7.5, this has to be changed to:
          order by random()

          Which already seems to be the case in this particular playlist, do you get the error with this one ?

          You can try hitting the "Refresh playlists" link at the bottom of the "Extras/SQL Playlists" menu in the SBS web interface, that should remove any cached information and make sure it creates the SQL based on the latest version.
          Erland Lindmark (My homepage)
          Developer of many plugins/applets
          Starting with LMS 8.0 I no longer support my plugins/applets (see here for more information )

          Comment

          • Tony T
            Senior Member
            • Nov 2009
            • 1469

            #6
            Originally posted by erland
            You can try hitting the "Refresh playlists" link at the bottom of the "Extras/SQL Playlists" menu in the SBS web interface, that should remove any cached information and make sure it creates the SQL based on the latest version.
            I did a 'clean install' of SBS Server, and its working!! (Might have been a cache problem as you suggested)

            Thanks!
            Tony
             SBTouch ♪ SBRadio ♬

            Comment

            • ae67
              Member
              • Apr 2009
              • 34

              #7
              Ran into a simular problem.

              Each playlist which contains "create temporary table" doesn't seem to work anymore.

              Without the temporary table everthing is fine.

              Comment

              • erland
                Senior Member
                • Jan 2006
                • 11323

                #8
                Originally posted by ae67
                Ran into a simular problem.

                Each playlist which contains "create temporary table" doesn't seem to work anymore.

                Without the temporary table everthing is fine.
                Yes, unfortunately those playlist types are not compatible with 7.6.
                Erland Lindmark (My homepage)
                Developer of many plugins/applets
                Starting with LMS 8.0 I no longer support my plugins/applets (see here for more information )

                Comment

                • ae67
                  Member
                  • Apr 2009
                  • 34

                  #9
                  Originally posted by erland
                  Yes, unfortunately those playlist types are not compatible with 7.6.
                  Is there an alternative.
                  My playlist should mix ratings:
                  10% new or notrated songs
                  40% songs with rating 5
                  20% songs with rating 4
                  10% songs with rating 3
                  and so on

                  Works great with 7.5 and it would be hard not to have it anymore.

                  Comment

                  • erland
                    Senior Member
                    • Jan 2006
                    • 11323

                    #10
                    Originally posted by ae67
                    Is there an alternative.
                    My playlist should mix ratings:
                    10% new or notrated songs
                    40% songs with rating 5
                    20% songs with rating 4
                    10% songs with rating 3
                    and so on

                    Works great with 7.5 and it would be hard not to have it anymore.
                    No alternative at the moment but I realize it's interesting functionality so it's on the list of things that we should try to support in a future version.

                    If anyone seeing this want to try figure out how the SQL should look like for the SQLite database, let me know. The "Random rated songs"(randomweightedtracks) template is one of those that have this problem.
                    Erland Lindmark (My homepage)
                    Developer of many plugins/applets
                    Starting with LMS 8.0 I no longer support my plugins/applets (see here for more information )

                    Comment

                    • ae67
                      Member
                      • Apr 2009
                      • 34

                      #11
                      Originally posted by erland
                      No alternative at the moment but I realize it's interesting functionality so it's on the list of things that we should try to support in a future version.

                      If anyone seeing this want to try figure out how the SQL should look like for the SQLite database, let me know. The "Random rated songs"(randomweightedtracks) template is one of those that have this problem.
                      Thanks for your help.
                      It seems I finally need to go back to 7.5. Don't want to loose this playlist.

                      Comment

                      Working...