INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Custom fields - 'store 1 value per album' problem  (Read 1750 times)

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Custom fields - 'store 1 value per album' problem
« on: July 20, 2021, 12:49:47 pm »

I am using some custom fields to store info for albums, for example "Discogs ID", "Catalog #" and "Source".

However, when the Artist and Album become the same, these values are inherited. The only way I know to prevent this from happening is to edit Album and add something (like (CD) or (SACD). This leads to other issues like fetching album covers.

Is there a way to control what MC sees as an "album"? I am really looking for a way to properly organize and keep multiple versions of the same album separate from each other. I would really like it if I could control which fields MC looks at (a tickbox in manage library fields, similar to 'default search field' perhaps).

Thanks for the help!
Logged

haggis999

  • Citizen of the Universe
  • *****
  • Posts: 514
Re: Custom fields - 'store 1 value per album' problem
« Reply #1 on: July 22, 2021, 07:38:51 am »

As far as I am aware, MC just accepts whatever Album name you choose to use.

I rip all my SACDs in three different versions: CD (FLAC), Stereo SACD (DSF) and Multi-channel SACD (DSF). Just like you, the only way I could find to keep all these rips under control within MC was to give each version a slightly different Album name (using the prefixes [CD], [SS] and [SM]). Any album-specific tags can thus be different for each version, should this be required. 

My CD rips are done using dBpoweramp and its automated search for album covers is usually quite successful. This search is triggered before I make any manual edits to the Album tag. Even when I do a manual online search, it usually takes me less than a minute to find the correct image. 
Logged

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Re: Custom fields - 'store 1 value per album' problem
« Reply #2 on: July 22, 2021, 08:05:23 am »

Well I'm hoping we can find a better solution because the current work around is just that: a work around. Its far from ideal. I am not so lucky with my manual or automated searches when album titles are changed with tags, it varies.

What if I have 3 CD versions? Should I name them "Album Title [CD1]", "Album Title [CD2]" and "Album Title [CD3]"? Or should I add something else like a catalog number, and what if that is the same (which is sometimes the case)? Personally I don't like adding tags to album names and I rather keep them clean of extraneous information that should be in their own field.

I'm hoping we can explore ways to keep the album title as it is supposed to be, and look for other ways to make MC keep albums apart. When files are in a separate folder would certainly help, but maybe we can get some form of control over which fields MC looks at, like the tickbox I suggested earlier? Maybe there are other ideas, things I haven't thought of.
Logged

Dawgincontrol

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 679
  • We have met the enemy and he is us.
Re: Custom fields - 'store 1 value per album' problem
« Reply #3 on: July 22, 2021, 09:48:01 am »

I have used the catalog number and put the type media in parenthesis. 

eg Jeff Beck Truth has Catalog# EMI 795469 (CD)
     Duke Ellington Meets Coleman Hawkins has Catalog# Impulse CIPJ-26-SA (SACD)

Could use any abbreviation/designation you like.  Quickly accessible in a list.

Logged

haggis999

  • Citizen of the Universe
  • *****
  • Posts: 514
Re: Custom fields - 'store 1 value per album' problem
« Reply #4 on: July 22, 2021, 12:52:47 pm »

What if I have 3 CD versions? Should I name them "Album Title [CD1]", "Album Title [CD2]" and "Album Title [CD3]"? Or should I add something else like a catalog number, and what if that is the same (which is sometimes the case)? Personally I don't like adding tags to album names and I rather keep them clean of extraneous information that should be in their own field.

Can you please give specific examples of a CD with three different versions, as I'm not sure I understand what you mean.
Logged

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Re: Custom fields - 'store 1 value per album' problem
« Reply #5 on: July 22, 2021, 01:35:12 pm »

Can you please give specific examples of a CD with three different versions, as I'm not sure I understand what you mean.

Sure.

1985 reissue, German release:
https://www.discogs.com/Elton-John-Madman-Across-The-Water/release/3080828
https://dr.loudness-war.info/album/view/186376

1995 remaster:
https://www.discogs.com/Elton-John-Madman-Across-The-Water/release/376815
https://dr.loudness-war.info/album/view/163609

2019 remaster SHM in paper sleeve:
https://www.discogs.com/Elton-John-Madman-Across-The-Water/release/13973778
https://dr.loudness-war.info/album/view/168559

There are many more of that same album, literally hundreds actually. Most of them are from the same digital source and will be identical, but the examples above are clearly different from each other (look at the DR numbers on the second link).

Almost every CD ever released will have multiple versions that sound different, because they were remastered, remixed or come from different tapes. Some were only dynamically compressed to make them sound louder.

For vinyl releases it can get even crazier. The same mastering could be pressed at different plants around the world from different lacquers, and sound very different from each other. This is particularly true for releases from the 60s to the 80s when vinyl was king. For the above album I have an LP which was never released as a CD (mastered specifically for vinyl).

If I wanted to differentiate some of those versions I would have to go crazy on the titles with barcodes or catalog numbers, but like I said, sometimes those numbers are the same and the difference can only be told from the matrix runouts on an LP (or CD, same thing).

And then there are digital downloads, HDtracks for example. Some albums were remastered specifically for that medium too.
Logged

haggis999

  • Citizen of the Universe
  • *****
  • Posts: 514
Re: Custom fields - 'store 1 value per album' problem
« Reply #6 on: July 22, 2021, 04:38:00 pm »

You made the point that your various versions of the 'Madman Across The Water' album are not the same as one another, so I don't really understand your reluctance to give them unique album names. Using the following suggestions would ensure that they are always listed together and the suffix would probably be enough for you to remember the differences.

Elton John - Madman Across the Water (19?? LP)
Elton John - Madman Across the Water (1985)
Elton John - Madman Across the Water (1995)
Elton John - Madman Across the Water (2019)

If a year flag was not appropriate to distinguish between another set of recordings, I'd recommend that you just find some other simple identifier that would do the job. All that matters is that you understand what that identifier means. Using something obscure like a barcode or catalogue number would not serve that purpose.


     
Logged

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Re: Custom fields - 'store 1 value per album' problem
« Reply #7 on: July 23, 2021, 01:48:18 am »

I don't really understand your reluctance to give them unique album names.   

I understand where you're coming from, I am using this way of distinguishing between album versions since forever and it has always bothered me because:
  • They are not unique albums, they are unique versions of the same album.
  • Any information I add to the album field is extraneous; its not suposed to be there.
  • It makes long album names even longer and long fields are cut off which makes album versions indistinguisable from each other in JRemote, Panel and Theater View.
  • It messes up other features like finding online information.
  • And last but not least, its not a solution to the problem.

If it works acceptably well for you all the better, just accept that it doesn't work very well for the above reasons, depending on how you use MC. I came to ask if there are other ways I hadn't thought about, some options I had missed. It looks like there isn't.

So in that case, wouldn't it be better if we get some control over what is an album? The default can be what is it is now which seems to work fine for the majority of users, and if someone wants to include another field to be evaluated for what constitutes an album, they can do so by ticking a box for the appropriate field. Or, imagine selecting a bunch of files which constitutes an album, right clicking them and select an option 'Group as Album'.

Let's make this a feature request :).
Logged

haggis999

  • Citizen of the Universe
  • *****
  • Posts: 514
Re: Custom fields - 'store 1 value per album' problem
« Reply #8 on: July 23, 2021, 04:44:48 pm »

I might have a solution for you, that works for me when I want to create a group of videos that belong to a box set of classical music (ripped from my Blu-ray collection). I would never wish to play an entire box set at one time, so I normally create a separate MKV file for each work within the set.

I created a custom tag called AlbumGroup. For videos within a box set, this tag would have a value such as 'Beethoven String Quartets Box Set', 'Sibelius Symphonies Box Set' and 'Shostakovich Box Set'. For all other videos, it is set to 'All Movies (exc special album groups)'.

My customised view for videos selects video thumbnails by Genre but is sorted by AlbumGroup, so my box sets each appear as a separate set of thumbnails.

Would something similar work for your version sets?
Logged

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Re: Custom fields - 'store 1 value per album' problem
« Reply #9 on: July 24, 2021, 02:05:41 am »

Maybe, I will need to experiment a bit to see if I can find a way that works better than only editing the [Album] field.

I'll give it some thought, thanks for thinking along!

For now, I am testing / trying the following:
Create a new library field called [Album Title]
Made it of type 'Calculated data'
With this expression:
Code: [Select]
Regex([Album], /#^(.+?)((\s*\[[^]]*\])|(\s*\([^)]*\)))?$#/, 1)
I've tested the regular expression on regex101 as
Code: [Select]
^(.+?)((\s*\[[^]]*\])|(\s*\([^)]*\)))?$ and tested it against several mutilated ::) album titles, like:
Code: [Select]
some album name [sacd]
another one (bla)
and yet another [sacd (dlx)]

It seems to work fine, it consistently marks the text between square brackets and braces, but in MC the field remains empty.

My regex foo isn't bad, but I'm no expert either, so any help here with what is going wrong?

Thanks!

Edit: Can an Administrator move this to the version 28 board please? I posted this before I upgraded, but have since upgraded to v.28. Thanks!
Logged

haggis999

  • Citizen of the Universe
  • *****
  • Posts: 514
Re: Custom fields - 'store 1 value per album' problem
« Reply #10 on: July 24, 2021, 05:16:11 am »

Your phrase "regex foo" had me scratching my head. What does that mean in plain English? I'm a Brit, so some American slang goes over my head :)

Several years ago, I made some very limited use of regex code in my website design activities, but never gained any meaningful skills. Such knowledge as I had back then has now been almost totally forgotten, so I'm unable to offer any real help with your regex expression. That said, I did confirm your regex101 test results. Your basic expression does indeed highlight (in pink) any suffix wrapped in round or square brackets.

That suggests you wanted your new calculated field [Album Title] to only contain such suffixes when found at the end of an Album title, in which case should your new field not be called [Album Suffix]?

I created a new calculated library field called [MyRegexTest] using your full expression Regex([Album], /#^(.+?)((\s*\[[^]]*\])|(\s*\([^)]*\)))?$#/, 1). Unlike you, this generated a result for all my audio files, but not the result I was expecting.

For my non-classical discs, the value of MyRegexTest was [Album] by [Artist], as in the following example.
Greatest Hits (2011 digital remaster) by Queen.

Note that there was no extraction of the text in round brackets. For my classical discs, MyRegexTest was always set to [Composer].

Things are getting curiouser and curiouser...
Logged

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Re: Custom fields - 'store 1 value per album' problem
« Reply #11 on: July 24, 2021, 06:20:31 am »

I should have written 'fu', not 'foo' (which comes from foo-bar). 'fu' comes from 'Kung Fu' and in the way I used it simply means 'skills'.

The expression with the regex should become the field [Album], and the regular expression searches for text between square and round brackets, then replaces it with nothing (s\ is the search and after the second \ the replacement), thus effectively removing the string it finds. The new field [Album Title] then becomes the [Album] field without a suffix. I must have gotten it wrong somehow though, or it would have worked haha!

I'm pretty sure it worked at one point, although Im not sure why I stopped using it.
Logged

zybex

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2616
Re: Custom fields - 'store 1 value per album' problem
« Reply #12 on: July 24, 2021, 06:42:28 am »

You have a typo in your regex - a missing escape for ']'. I also replaced ? with * at the end to catch multiple parenthesis groups:
Regex([Album], /#^(.+?)((\s*\[[^\]]*\])|(\s*\([^)]*\)))*$#/, 1)

Note that this is more or less the same as:
Trim(Regex([Album], /#([^(\[]*)#/,1))


You can use Zelda to test these expressions.
Logged

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Re: Custom fields - 'store 1 value per album' problem
« Reply #13 on: July 24, 2021, 07:15:50 am »

You have a typo in your regex - a missing escape for ']'. I also replaced ? with * at the end to catch multiple parenthesis groups:
Regex([Album], /#^(.+?)((\s*\[[^\]]*\])|(\s*\([^)]*\)))*$#/, 1)

Note that this is more or less the same as:
Trim(Regex([Album], /#([^(\[]*)#/,1))


You can use Zelda to test these expressions.

Thanks!!

first thing I did when it didnt work is download the latest Zelda  :P. What I couldnt figure out was how to let it show album titles, I could only get it to show tracks.

Logged

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Re: Custom fields - 'store 1 value per album' problem
« Reply #14 on: July 24, 2021, 07:26:46 am »

I don't understand why MC is showing me album titles correctly without suffices, but instead shows three dots, like:

'Madman Across The Water...'

So it turns
'Little Girl Blue (2013 remaster)'
into
'Little Girl Blue...'

What I don't get is where the 3 dots are coming from?
Logged

zybex

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2616
Re: Custom fields - 'store 1 value per album' problem
« Reply #15 on: July 24, 2021, 07:36:10 am »

It means there's a second line of text, probably blank. Did you type a newline (Enter) after your expression?
Logged

zybex

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2616
Re: Custom fields - 'store 1 value per album' problem
« Reply #16 on: July 24, 2021, 07:41:33 am »

Zelda only shows a list of tracks, not albums, as the Expressions on MC also always work on a single track. So the track you select is the current context for any expression you execute.

You can just type [Album] on one line of the editor, and type your expression a couple of lines below it - then you can see on the 'Text Output' tab both the Album name and the result of your expression.

Alternatively, You can select the 'Playlist' tab and click the icon on the top-right corner to add columns to the view, like Album. In this tab, it shows the result of your expression for each track on the playlist you selected. To work in this mode it's best to write your expression on a single line of text of the editor.

One last tip: you can create a playlist in MC called 'Zelda testing' and drag your problematic tracks/albums into it. Then just select that list in Zelda to test expressions on it.
Logged

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Re: Custom fields - 'store 1 value per album' problem
« Reply #17 on: July 24, 2021, 07:43:49 am »

It means there's a second line of text, probably blank. Did you type a newline (Enter) after your expression?

Cool, that was it.

Thank you! I think I can work with this, I can hide the regular [Album] field replace it with [Album Title] in the regular views.
Logged

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Re: Custom fields - 'store 1 value per album' problem
« Reply #18 on: July 24, 2021, 07:48:05 am »

Zelda only shows a list of tracks, not albums, as the Expressions on MC also always work on a single track. So the track you select is the current context for any expression you execute.

You can just type [Album] on one line of the editor, and type your expression a couple of lines below it - then you can see on the 'Text Output' tab both the Album name and the result of your expression.

Alternatively, You can select the 'Playlist' tab and click the icon on the top-right corner to add columns to the view, like Album. In this tab, it shows the result of your expression for each track on the playlist you selected. To work in this mode it's best to write your expression on a single line of text of the editor.

One last tip: you can create a playlist in MC called 'Zelda testing' and drag your problematic tracks/albums into it. Then just select that list in Zelda to test expressions on it.

Awesome. Thanks again!

i'll leave some feedback in the zelda thread :P
Logged

haggis999

  • Citizen of the Universe
  • *****
  • Posts: 514
Re: Custom fields - 'store 1 value per album' problem
« Reply #19 on: July 24, 2021, 08:41:57 am »

You have a typo in your regex - a missing escape for ']'. I also replaced ? with * at the end to catch multiple parenthesis groups:
Regex([Album], /#^(.+?)((\s*\[[^\]]*\])|(\s*\([^)]*\)))*$#/, 1)

Note that this is more or less the same as:
Trim(Regex([Album], /#([^(\[]*)#/,1))


I modified the [MyRegexTest] calculated field I created for the purpose of participating in this thread to use these revised regex expressions. Neither of them made any difference to the results I get. My album named Greatest Hits (2011 digital remaster) still generates a MyRegexTest value of Greatest Hits (2011 digital remaster) by Queen. I had expected a result of Greatest Hits, i.e. with the bracketed suffix removed and no reference to the artist. 

Have I misunderstood the purpose of these regex expressions?
Logged

zybex

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2616
Re: Custom fields - 'store 1 value per album' problem
« Reply #20 on: July 24, 2021, 09:02:22 am »

You may have (or I may have). The expression above only works for [album]. Are you trying to cleanup something else, like "[album] by [artist]"? If so, a change is needed. Please post your full expression.
Logged

haggis999

  • Citizen of the Universe
  • *****
  • Posts: 514
Re: Custom fields - 'store 1 value per album' problem
« Reply #21 on: July 24, 2021, 09:10:47 am »

You may have (or I may have). The expression above only works for [album]. Are you trying to cleanup something else, like "[album] by [artist]"? If so, a change is needed. Please post your full expression.

I simply copied and pasted Trim(Regex([Album], /#([^(\[]*)#/,1)) from your earlier post and used that as the calculated definition for the MyRegexTest library field.

BTW, I've just downloaded Zelda for the first time and have noted that this same regex expression correctly generates Greatest Hits from the album named Greatest Hits (2011 digital remaster). The problem appears to centre on what MC does with calculated fields rather than being an issue with your regex.   
Logged

zybex

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2616
Re: Custom fields - 'store 1 value per album' problem
« Reply #22 on: July 24, 2021, 09:17:20 am »

Your [MyRegexTest] can only generate a value of "Greatest Hits (2011 digital remaster) by Queen" if the expression uses both the [Album] and [Artist] fields. Is it defined as "[Album] by [Artist]" ? Or is the "by Queen" part of the album name itself?

If you're using both fields, you need something like "Trim(Regex([Album], /#([^(\[]*)#/,1)) by [Artist]".

If you're still having issues, please post the full expression you have on [MyRegexTest].
Logged

haggis999

  • Citizen of the Universe
  • *****
  • Posts: 514
Re: Custom fields - 'store 1 value per album' problem
« Reply #23 on: July 24, 2021, 10:37:01 am »

I had added a reference to [MyRegexTest] as the first column in the details pane of my normal music view. I misread the text immediately below that heading as the first value for that field when in fact it was the heading generated by MC (in Album by Artist format). The real values for that tag started in the next line and they were fine.

In other words, it's working as expected. Apologies for the confusion.

My brain does not work at full capacity during the very humid weather we are currently 'enjoying' here in the UK, where very few homes have air conditioning. It's either that or I need new glasses! :)
Logged
Pages: [1]   Go Up