• Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    How to restore stats

    Scheduled Pinned Locked Moved Technical Help
    sqldatabaselibraryratingplaycount
    5 Posts 2 Posters 2.8k Views 1 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M
      mbnoimi
      last edited by mbnoimi

      Hi,

      Recently I bought a new PC so I copied Strawberry config folders to the new PC for restoring the statistics (playcounts & ratings) and the configurations of my library but it didn't work for the stats although I use the same user name (exactly the same path)

      ~/.config/strawberry
      ~/.local/share/strawberry/
      

      What I'm missing?

      • Linux Mint 20.2 XFCE
      • Strawberry 0.9.3
      1 Reply Last reply
      Reply Quote 0
      • M
        mbnoimi
        last edited by mbnoimi

        I opened the original strawberry.db for comparing with the new one and I noticed the difference.
        It seems the paths of my library are not the same (I enhanced my library without updating old strawberry.db) so songs.url values are different.

        Example:

        • Original: songs row is
        INSERT INTO "main"."songs" ("title", "album", "artist", "albumartist", "track", "disc", "year", "originalyear", "genre", "compilation", "composer", "performer", "grouping", "comment", "lyrics", "artist_id", "album_id", "song_id", "beginning", "length", "bitrate", "samplerate", "bitdepth", "source", "directory_id", "url", "filetype", "filesize", "mtime", "ctime", "unavailable", "playcount", "skipcount", "lastplayed", "compilation_detected", "compilation_on", "compilation_off", "compilation_effective", "art_automatic", "art_manual", "effective_albumartist", "effective_originalyear", "cue_path", "rating") VALUES ('SALAMUN ALA DUNYA', 'SALAMUN ALA DUNYA', 'Adam Ali', 'Adam Ali', '-1', '-1', '2018', '-1', '', '0', '', 'Adam Ali', '', '', '', '', '', '', '0', '125016000000', '260', '48000', '-1', '2', '1', 'file:///home/mbnoimi/Music/Adam%20Ali/SALAMUN%20ALA%20DUNYA/SALAMUN%20ALA%20DUNYA.mp3', '8', '4060798', '1595214021', '1590594062', '0', '31', '4', '1625400994', '0', '0', '0', '0', '', '', 'Adam Ali', '-1', '', '0.800000011920929');
        
        • Current: songs row is
        INSERT INTO "main"."songs" ("title", "album", "artist", "albumartist", "track", "disc", "year", "originalyear", "genre", "compilation", "composer", "performer", "grouping", "comment", "lyrics", "artist_id", "album_id", "song_id", "beginning", "length", "bitrate", "samplerate", "bitdepth", "source", "directory_id", "url", "filetype", "filesize", "mtime", "ctime", "unavailable", "playcount", "skipcount", "lastplayed", "compilation_detected", "compilation_on", "compilation_off", "compilation_effective", "art_automatic", "art_manual", "effective_albumartist", "effective_originalyear", "cue_path", "rating") VALUES ('SALAMUN ALA DUNYA', 'SALAMUN ALA DUNYA', 'Adam Ali', 'Adam Ali', '-1', '-1', '2018', '-1', '', '0', '', 'Adam Ali', '', '', '', '', '', '', '0', '125016000000', '260', '48000', '-1', '2', '1', 'file:///home/mbnoimi/Music/Adam%20Ali/SALAMUN%20ALA%20DUNYA/Adam%20Ali%20-%20SALAMUN%20ALA%20DUNYA%20-%20SALAMUN%20ALA%20DUNYA.mp3', '8', '4060798', '1629923620', '1630573650', '0', '0', '0', '-1', '0', '0', '0', '0', '', '', 'Adam Ali', '-1', '', '-1');
        

        Do you have any suggest for restoring playcount and rating values?

        jonasJ 1 Reply Last reply
        Reply Quote 0
        • jonasJ
          jonas @mbnoimi
          last edited by

          @mbnoimi
          You can either use the original DB file and modify the paths with SQL commands before you start strawberry.
          The other option is to import the data to the new DB based on artist/album/title, you can use parts of the guide I made here, but you have to modify the query to import only playcounts and rating from the other DB.

          https://github.com/strawberrymusicplayer/strawberry/wiki/Import-collection-library-and-playlists-data-from-Clementine
          

          I plan to make a new release soon, there will be an option to turn on song fingerprinting and tracking to prevent losing playcounts and ratings.

          M 2 Replies Last reply
          Reply Quote 0
          • M
            mbnoimi @jonas
            last edited by

            @jonas said in How to restore stats:

            The other option is to import the data to the new DB based on artist/album/title, you can use parts of the guide I made here, but you have to modify the query to import only playcounts and rating from the other DB.

            Thanks a lot for the good guide.

            @jonas said in How to restore stats:

            I plan to make a new release soon, there will be an option to turn on song fingerprinting and tracking to prevent losing playcounts and ratings.

            I prefer to wait for your release in case you'll produce it within less than 1 month. Do you?

            1 Reply Last reply
            Reply Quote 0
            • M
              mbnoimi @jonas
              last edited by

              @jonas said in How to restore stats:

              I plan to make a new release soon, there will be an option to turn on song fingerprinting and tracking to prevent losing playcounts and ratings.

              The recent release (Version 1.0) still doesn't fix this issue.

              1 Reply Last reply
              Reply Quote 0

              Hello! It looks like you're interested in this conversation, but you don't have an account yet.

              Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

              With your input, this post could be even better 💗

              Register Login
              • First post
                Last post
              Powered by NodeBB | Contributors