Error Importing tags from file

Hello,
I'm trying to import from the filename to tag:
02 Canto Extranjero (Canto Straniero) (1981)

with this string
%track% %title% (%title%) (%year%)

but the result is :
(track) 02
Canto Extranjero Canto Straniero
year 1981

how do I get this result:
(track) 02
(title) Canto Extranjero (Canto Straniero)
year 1981

Thanks in advance (and sorry for my bad english)

Franco

What about
%track% %title%) (%year%)
You loose the closing bracket in the title but that should easily be added.

1 Like

Yes, playing with brackets and spaces I saw that I could achieve this.
But that's not what I wanted so badly...

You could import everything into just title (including the year)
then copy all of TITLE into YEAR,
leave only the 4 digits in YEAR
remove the 4 digits and the brackets in TITLE

  • many more steps than just use the converter filename-tag
    and then the converter tag-tag with
    Format string: %title%)

The problem with the original filename is that the separator in one case can be omitted while in the other case should be included in the data.

Try an Action Group made up of these 3 actions:

Action type: Format value
Field: TRACK
Format string: $regexp(%_filename%,^(\d\d)(.+)\((\d\d\d\d)\)$,$1)

Action type: Format value
Field: TITLE
Format string: $trim($regexp(%_filename%,^(\d\d)(.+)\((\d\d\d\d)\)$,$2))

Action type: Format value
Field: YEAR
Format string: $regexp(%_filename%,^(\d\d)(.+)\((\d\d\d\d)\)$,$3)

1 Like