Is there a way to create action which generates one common unique identifier (UUID) to all selected tracks. Not unique to each of selected tracks, but one which is same to all of them.
I don't know about the generating algorithm - but you can set an ID with Convert>Tag-Tag for the target field.
Enter as format string the id that you want to apply.
My description was bit unclear. I mean I am looking for a this kind of solution: generate one UUID and then use it for all selected tracks. This is how I am doing it now:
- Select tracks
- Then start action which generates UUID for all the tracks
- Then manually update one of the generated UUID for all selected tracks
I like to have a action for the last two steps so I wouldn't have to do that manual step
You want to generate 1 UUID.
Then you want to apply this 1 UUID to all selected tracks.
All the selected tracks becomes the same UUID?
I'm just curious: why do you want to do this?
I like to have unique identifier for the album.
I like that too.
But I use the MUSICBRAINZ_ALBUMID (as one possible UUID) for this purpose.
This ID will be set automatically by the various Web Source scripts.
At the moment, I am also using MUSICBRAINZ_ALBUMID for this purpose. It works great, but sometimes I have album which cannot be found from musicbrainz library. Then I have two options: insert the album to musicbrainz to myself, or use some other unique number instead.
Yes. That is more or less what I described.
The only thing is: MP3tag does not remember which ids it has used so far. You would have to do the bookkeeping.
And once you know which ID you want to set, transfer it to the files in the already described way.
If it is too time-consuming to add the metadata at MusicBrainz myself right away, I use a third option: I leave the ID empty.
And then, sometimes later, I re-check such empty MUSICBRAINZ_ALBUMIDs again with MusicBrainz.
The main reason why I add MUSICBRAINZ_ALBUMIDs to my albums is not the need to have them connected the certain album which can be found from the musicbrainz library (although that is nice thing to have). The main reason (for me) is just have some unique album id. I am using LMS (Lyrion) for my music server and it gets confused if there is a multiple versions of multidiscs albums. For example I have three versions of The Beatles album (=White album) and if the albums don't have unique MUSICBRAINZ_ALBUMIDs then LMS thinks that there is only one album with 6 discs.
And how are you doing that now?
Really, a player relies on a user-defined, database specific tag field to keep albums apart?
Anyway:
If you do not really care about the accuracy of an ID, set the current date and time as ID - that should be unique enough.
e.g. with
$replace(%_datetime%,.,,:,, ,)
Using mp3tag's $uuid() function.
Sorry, I don't quite understand how $replace(%_datetime%,.,,:,, ,) would solve the problem. Isn't it the same thing with that ? Every track gets "unique" id? Or am I missing something?
If the action runs quick enough, then you get the same date for all files.
Alternatively: try Convert>Tag-Tag for the ID field with
Format string: $replace(%_datetime%,.,,:,, ,)
and use the data from the preview which you paste into the format string. Then you don't have to keep track which IDs you have used already and you don't run into problems, if $UUID() always starts with the same value.
And another suggestion, that works without the preview and copy& paste:
Format string: $div($replace(%_datetime%,.,,:,, ,),%_total_files%)
this takes the number of selected files into the calculation and keeps the value constant for the selected files.
Just to chime in a 4th option: I use mainly ITUNESALBUMID as UUID source for my albums, and use MUSICBRAINZ_ALBUMID when I can't get results from the primary database. If that fails, I also use DISCOGS_RELEASE_ID and CATALOGNUMBER (from VGMdb). Since OP is only after *a* UUID (string format doesn't seem to be important) my suggestion is to use UUIDs from various databases.