Hi there: I want to extract part of the filename and compare that value to the value in the Title field.
Basically, I want to compare everything after the first hyphen and before the file extension to the value in the Title field.
An example of my file name is:
Artist Name - Song Title.mp3
Mind you I want to be able to compare whatever comes after the hyphen and before the file extension even if it doesn't exactly match the example above.
What exactly do you want to do with Song Title in your example?
If you don't already have Song Title in the TITLE field, what do you want to do?
Replace the current content? Append it to the current content?
Or do you want to create a new custom column to visually compare it with TITLE?
Or you could add an new custom column.
As name you can choose whatever you want.
As Value use $if($strcmp($regexp(%_FILENAME%,.*?- (.*),$1),%TITLE%),yes,no)
As always if you use regular expressions: They only work for the given example.
In your case with some text in front of a space and a hyphen and a space and some other text that will be compared with the content of TITLE.
In particular, characters such as : (colon) and ? (question mark), which frequently occur in TITLEs but are invalid in Windows filenames.
And some more: