title
Products            Buy            Support Forum            Professional            About            Codec Central
 

Can I batch-rename every song to begin with its track number?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Redd

    • May 2014
    • 43

    Can I batch-rename every song to begin with its track number?

    Honest. You see, I keep my library organized by artist\album\track-name and every music player or radio I've ever met has been happy to just dig the track number up from the metadata, and play the tracks in any one album, in track order.

    Nope.

    I've got the library on a USB stick to feed the new car, and the car's "music system" only knows how to read alphabetically, so it only plays cuts in alphabetical order. Which is NOT the correct track order, and certainly not how the artists intended the album to be played. Much less how I'm used to hearing it.

    So, if I listen to random cuts...no problem, that's random. But if I want to hear an ALBUM in the original sequence, that's not possible.

    And I'm not about to rename the tracks in a thousand albums all manually, just to placate a dumb car stereo.

    So is there any way...I'm using dbp, paid, the whole thing, any way that I can tell it "Go rename all the songs in this library, take their track number and make sure to use a leading zero for the single digit ones (REALLY dumb stereo!), and rename them as "Track01-SongTitleWhatever" instead of just the existing song title?

    It should be scriptable, I just have no idea what or how to being doing that without doing custom programming.
  • mville
    dBpoweramp Guru

    • Dec 2008
    • 4021

    #2
    Re: Can I batch-rename every song to begin with its track number?

    Download and install the Arrange Audio utility codec from here:
    dBpoweramp Codec Central: Utility Codecs

    You can run it using dBpoweramp Batch Converter

    You may need to consider using the disc number tag as well as the track number tag.
    e.g. [disc].[track] [artist] - [title]

    Another option, is to use MP3Tag, which I prefer for this type of manipulation.
    Last edited by mville; December 30, 2015, 07:53 PM. Reason: added MP3Tag reference

    Comment

    • Redd

      • May 2014
      • 43

      #3
      Re: Can I batch-rename every song to begin with its track number?

      I did look at MP3tag, but I don't see any clear way to do the batch renaming the way I want to, i.e. a list of parameters or way to specify syntax like "Track*""TitleName" etc.
      Could be I'm suffering from a caffeine shortage. WHile I look for the coffee and the Arrange Audio codec, could you give me some specific hints about how to set up either one?

      Thanks.

      Comment

      • garym
        dBpoweramp Guru

        • Nov 2007
        • 5905

        #4
        Re: Can I batch-rename every song to begin with its track number?

        Originally posted by Redd
        I did look at MP3tag, but I don't see any clear way to do the batch renaming the way I want to, i.e. a list of parameters or way to specify syntax like "Track*""TitleName" etc.
        Could be I'm suffering from a caffeine shortage. WHile I look for the coffee and the Arrange Audio codec, could you give me some specific hints about how to set up either one?

        Thanks.
        EdIT: obviously test all this with a few tracks before changing name on thousands of files.

        I suspect your car is not using tags at all, but instead using FILE NAMES. To change the file names:

        1. Load up all files in mp3tag. Select all.
        2. from menu select CONVERT, then TAG to Filename
        3. use this mapping to get track number (with double digits)-title of track
        $num(%track%,2 )-%title%

        If you want disk no too:
        %discnumber%.$num(%track%,2 )-%title%

        if you want artist at the end of file name, you can always add %artist% somewhere in the string (at end?).

        All the above will change the filename, but will leave the files in the same ALBUM or ARTIST/ALBUM subdirectory they were already in. mp3tag can also be used to change directory name/location, but that's not being done above.
        Last edited by garym; December 31, 2015, 08:16 PM.

        Comment

        • Redd

          • May 2014
          • 43

          #5
          Re: Can I batch-rename every song to begin with its track number?

          "I suspect your car is not using tags at all, but instead using FILE NAMES.
          Oh, I can tell you that for certain. Which is why I asked about renaming the files--not changing the tags.

          The process sounds foolproof enough, I'll have to make a test run and them see about clearing enough space to make a copy of the mp3 library that is all "misnamed" that way, for the car.

          As my zen master keeps reminding me, "But, take great comfort,, at least you don't have Takata air bags." (G)

          Comment

          • garym
            dBpoweramp Guru

            • Nov 2007
            • 5905

            #6
            Re: Can I batch-rename every song to begin with its track number?

            Originally posted by Redd
            As my zen master keeps reminding me, "But, take great comfort,, at least you don't have Takata air bags." (G)
            Yes! And Happy New Year!

            Comment

            • Redd

              • May 2014
              • 43

              #7
              Re: Can I batch-rename every song to begin with its track number?

              Well, not being a football fan, I took some time to try running the batch conversion today. First I ran it against just one folder, one artist, one album. Success!

              So I set it loose on 14,000 and it stalled out, still "running" but doing nothing, after about two hours halfway through. Two hours later I killed it and went to take a look.

              Some folders were just fine, it renamed and overwrote (this was a duplicate USB stick) in the desired artist/album/track*-tracktitle format. Others...indicate the need for more sophisticated scripting. When there are multiple artists indicated (like a collection album) it of course shotgunned them, each to a separate folder, no longer an album. Ooops. And then, if the folder name didn't exactly match the metatag's album name, the album art stayed put--but the songs went into a new folder with the precisely correct name. Not to mention, since I aborted it after the lockup, I'm not at all sure what might be missing or corrupt: Time to start over.

              So...I'm not sure if I want to use "my" version of the album name, or the metatag's version of it. But even ignoring that...I'll have to study up on the conditional commands to see how to deal with ignoring the artist's name in those "various" albums.

              Comment

              • mville
                dBpoweramp Guru

                • Dec 2008
                • 4021

                #8
                Re: Can I batch-rename every song to begin with its track number?

                Originally posted by Redd
                Ooops. And then, if the folder name didn't exactly match the metatag's album name, the album art stayed put--but the songs went into a new folder with the precisely correct name. Not to mention, since I aborted it after the lockup, I'm not at all sure what might be missing or corrupt: Time to start over.

                So...I'm not sure if I want to use "my" version of the album name, or the metatag's version of it.
                This is where MP3Tag is far more powerful than anything I have used when it comes to complicated tagging issues.

                For example, MP3Tag is able to show you (filter) all files where the album tag is not equal to the folder name, before processing any data using filter:
                "$if($neql(%album%,%_directory%),yes,no)" IS yes

                MP3Tag would also help in the other scenarios you mention here.

                For me, it is the definitive tool for consolidating my tags and obtaining uniformity across my audio library.
                Last edited by mville; February 08, 2016, 02:55 AM. Reason: working example

                Comment

                • garym
                  dBpoweramp Guru

                  • Nov 2007
                  • 5905

                  #9
                  Re: Can I batch-rename every song to begin with its track number?

                  Originally posted by Redd
                  Well, not being a football fan, I took some time to try running the batch conversion today. First I ran it against just one folder, one artist, one album. Success!

                  So I set it loose on 14,000 and it stalled out, still "running" but doing nothing, after about two hours halfway through. Two hours later I killed it and went to take a look.

                  Some folders were just fine, it renamed and overwrote (this was a duplicate USB stick) in the desired artist/album/track*-tracktitle format. Others...indicate the need for more sophisticated scripting. When there are multiple artists indicated (like a collection album) it of course shotgunned them, each to a separate folder, no longer an album. Ooops. And then, if the folder name didn't exactly match the metatag's album name, the album art stayed put--but the songs went into a new folder with the precisely correct name. Not to mention, since I aborted it after the lockup, I'm not at all sure what might be missing or corrupt: Time to start over.

                  So...I'm not sure if I want to use "my" version of the album name, or the metatag's version of it. But even ignoring that...I'll have to study up on the conditional commands to see how to deal with ignoring the artist's name in those "various" albums.
                  Yes, you'd certainly want to filter out the compilation albums (mp3tag has a filter option, so filter on COMPILATION = 1) and then convert those separately using different commands (I put my compilations into x:/compilations\albumname\trackno - track name - track artist.xxx format.

                  Comment

                  • Redd

                    • May 2014
                    • 43

                    #10
                    Re: Can I batch-rename every song to begin with its track number?

                    Ah, thanks. It tool me three tries to notice the "FILTERS" window at the bottom, rather than a top-level tool or option from the menus. And I while longer to find the help for filters...which will make better sense after a good night's sleep and fresh coffee, I hope.(G) Some of the compilations aren't tagged as compilations (i.e. a soundtrack album has various artists, but as "a" soundtrack, it was never originally tagged as a compilation) so that's still going to be problematic. I have a creeping feeling that if I can't get foldernames to be respected, or to get the program to just run recursively so that it does "everything in a folder" and then moves down or over to the next folder, overwriting just the song titles without trying to move them elsewhere, I may need to do a lot of manual checking and sorting.

                    I had a recursion tool like that (it would run any DOS command recursively, on every folder in a tree, each separately) but nothing like that for Windows.

                    Comment

                    • garym
                      dBpoweramp Guru

                      • Nov 2007
                      • 5905

                      #11
                      Re: Can I batch-rename every song to begin with its track number?

                      You can easily use mp3tag in a batch manner to change every album tag name to the name of its directory if that's what you want.

                      p.s. you're learning the lesson many of have also learned (sometimes the hard way). That is, getting secure bitperfect rips of CDs is easy. Getting good, complete, consistent metadata is a lifetime job!
                      Last edited by garym; February 08, 2016, 12:59 PM.

                      Comment

                      • Redd

                        • May 2014
                        • 43

                        #12
                        Re: Can I batch-rename every song to begin with its track number?

                        gary-
                        Good metadata, ROFL. I'd be happy if they would just break the tracks where the tracks actually break, i.e. in between sets on live concert cd's, rather than a couple of seconds into the previous or following set. I keep promising myself I'll go into Audacity and fix some of those when I remember to mark them down.(G)

                        But no, I don't want to change the album tag names. The goal was, and is, to outfox a stupid car music system which only plays tracks in alphabetical order, ignoring track numbers. So I want to go over an existing large library, and not change a thing--except to put the track number in the front of each track name.

                        I don't find an easy way, or any obvious way, in dbpa or mp3tag to just "walk down the directory tree and rename and overwrite every file, without moving any of them or changing any other attributes".

                        Did I forget to look under the doormat?(G)

                        Comment

                        • garym
                          dBpoweramp Guru

                          • Nov 2007
                          • 5905

                          #13
                          Re: Can I batch-rename every song to begin with its track number?

                          your goal should be trivial in mp3tag because you're just changing the filename (and not directory location or tags).

                          1. load up all your files in mp3tag
                          2. Select them all
                          3. from menu select CONVERT, then "tag to filename"
                          4. then in the naming popup box enter:

                          %track% - %title%

                          This gives you 01- trackname as filename, but leaves everything in same folder it started in. If you want more info in the filename use something like:
                          %track% - %title% - %artist%, or %track% - %title% - %artist% - %album%, etc.

                          This renames the FILENAMES of each track without moving anything or changing the folder that anything is in. (there are ways to do this too, but that doesn't seem to be what you need to do)

                          Comment

                          • mville
                            dBpoweramp Guru

                            • Dec 2008
                            • 4021

                            #14
                            Re: Can I batch-rename every song to begin with its track number?

                            As mentioned earlier in this thread, depending on how you handle multi disk CDs, you might want to consider adding the disc number tag to the example garym has given above, otherwise tracks may not be sequential in order.

                            I'm not sure why files are getting moved around your directory structure at all. As long as all your files have the disc number, track number and title tags, the file rename with MP3Tag is very straight forward.

                            Comment

                            • Redd

                              • May 2014
                              • 43

                              #15
                              Re: Can I batch-rename every song to begin with its track number?

                              mv-
                              I wasn't talking about MP3TAG changing the directory structure, but rather, when dbpa and the option ran, they require a "target" directory for each operation. You can't just say "stay here and overwrite" you define how "here" will be imagined. So if "here" was a folder named for the artist, but the songs in a soundtrack album were each by a different artist, the one album now splits into a dozen separate new folders.

                              gary-
                              Inf***ingcredible! It is churning away per your "well, duh, that's obvious" instructions. The USB stick is glowing cherry red from all the activity on it (G) but I have high hopes from the preview that this is exactly what I needed. A thousand thanks!

                              I've been thinking about painting a small German flag under my driver's side window, actually a row of them, each representing a successful "bombing" and conquest of some German madman's way of trying to build a car. ("No, you will not listen to those songs in that order. You will listen to them in THIS order, or you will not listen to them at all!") I'll make sure that one gets your name on it as well.(G)

                              Real fun when it tries to do that to audiobook chapters, too.

                              Just hoping it runs to conclusion (it's about halfway through) without the USB stick slagging down.(G)

                              [shortly later]
                              Not bad! It missed, without comment, about 125 out of 14,500. A quick glance shows some oddballs like the original track having been tagged "2/11" instead of "02" and the result being tagged 211. And at least two collection albums that apparently didn't have their own name in their tags to being with...a couple of oddities that prove Hollywood is still cheaping out whenever they can. But if that's all I have to manually fix...I can live with it!
                              Last edited by Redd; February 09, 2016, 12:33 AM.

                              Comment

                              Working...

                              ]]>