INTERACT FORUM

Please login or register.

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

Author Topic: Find duplicates of album titles removing (..) [Solved]  (Read 1420 times)

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Find duplicates of album titles removing (..) [Solved]
« on: September 21, 2013, 03:05:14 pm »

Using this to find duplicates:

[Track #]=1 [Disc #]=<=1 ~dup=[Album],[Album Artist /(auto/)] ~a ~sort=[File Type],[Album Artist (auto)],[Date (year)],[Album],[Track #],[Disc #]

But since I've been adding things like (remaster) or [MFSL] to album titles I'm no longer find duplicates.

I'm not sure how I can do this in that expression? The addition is always between (..) or [..].

Thanks for the help!
Logged

MrC

  • Citizen of the Universe
  • *****
  • Posts: 10462
  • Your life is short. Give me your money.
Re: Find duplicates of album titles removing (..)
« Reply #1 on: September 21, 2013, 03:43:27 pm »

You'll need to create a custom field that modifies Album, such as Album (base) which is calculated to strip away the variant:

    Regex([Album], /#^(.+?)((\s*\[[^]]*\])|(\s*\([^)]*\)))?$#/, 1)

and use [Album (base)] in your duplicates smartlist query.
Logged
The opinions I express represent my own folly.

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Re: Find duplicates of album titles removing (..)
« Reply #2 on: September 21, 2013, 04:19:08 pm »

Uhm ...

Did you mean create a new calculated field [Album (base)] and use the expression Regex([Album (base)], /#^(.+?)((\s*\[[^]]*\])|(\s*\([^)]*\)))?$#/, 1)?

Because that works but I can't seem to use that new field in ~dup=[Album (base)],[Album Artist /(auto/)]. When I try that via import expression, MC removes that field and leaves me with [Album Artist /(auto/)] only?

Edit: i think i got it, I need to escape the parens :P.
Logged

MrC

  • Citizen of the Universe
  • *****
  • Posts: 10462
  • Your life is short. Give me your money.
Re: Find duplicates of album titles removing (..)
« Reply #3 on: September 21, 2013, 04:21:07 pm »

Yes, that's what I meant.  Sorry.  Corrected.
Logged
The opinions I express represent my own folly.

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Re: Find duplicates of album titles removing (..)
« Reply #4 on: September 21, 2013, 04:23:26 pm »

Nope, escaping doesn't work. The field is not selectable.
Logged

MrC

  • Citizen of the Universe
  • *****
  • Posts: 10462
  • Your life is short. Give me your money.
Re: Find duplicates of album titles removing (..)
« Reply #5 on: September 21, 2013, 04:48:28 pm »

Sometimes after adding a new field, you have to restart MC to get the rest of the UI to see the field.
Logged
The opinions I express represent my own folly.

InflatableMouse

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3978
Re: Find duplicates of album titles removing (..)
« Reply #6 on: September 22, 2013, 01:41:31 am »

Thanks MrC, its working now.

Had to restart Media Server as well, I tend to forget that's running.
Logged
Pages: [1]   Go Up