INTERACT FORUM

Please login or register.

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

Author Topic: How to generate a list (file) of all values of a tag field in a library?  (Read 2553 times)

couchjr

  • World Citizen
  • ***
  • Posts: 121

Folks, I'm trying to standardize the data in the Composer tag field for a very large library (where values are saved into the media files). I'm working with a colleague who has used MusiCHI's composer database and there are some discrepancies between the composer lists (the way dates are formatted, a few variant spellings, etc.). If I do a search in MC on a composer name, select all the records in the results list, go into the action-> tag pane and bring up the pick list for the composer field, and edit the composer value in question, all those records will be updated. (If there's a more direct method to do this, please do tell.)

My question is: how in MC can I generate a text list (preferably one name per line) that I can use to compare (using diff software) with a similar list that MusiCHI produces so that I can isolate the composers whose tag values need to be updated?

The only way I know of now to see all the values is to "Select all" in album view for the entire library and then look at the pick list generated for the "Composer" tag field. But that won't show the entire list without scrolling and I don't know how to save it as a text file. Is there an expression language way to do this? If so, please be explicit since I don't understand expression languages well enough to compose in them. Or some other nifty trick? I know MC has very powerful database functionality and I haven't scratched the surface.

Thanks in advance for your help!
Logged

blgentry

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 8014
Re: How to generate a list (file) of all values of a tag field in a library?
« Reply #1 on: November 24, 2015, 03:58:25 pm »

That's an interesting project.  I'm pretty sure you can get exactly what you're after with a smartlist.

Make a new smartlist.  Call it composers, or something else descriptive.  Edit the smartlist.  Press the import/export button at the lower left corner and paste in this definition:

Code: [Select]
[Media Type]=[Audio] ~nodup=[Composer] ~sort=[Composer]
That will give you a list of songs and it will also be a unique list of composers, sorted by composer name.

Now, right click on the column headers and add Composer, so you can see it.  Next, right click on the column headers and remove all of the columns you don't want to see; probably all of the remaining ones.  Then you can select all, do Edit > Copy and copy the list to the clipboard.  Finally, you can paste this into a text editor.  But be careful with TextEdit!  By default when you try to paste into TextEdit it will try to paste the actual binary files; not the file list.  So either use a different editor, or select Edit > "Paste and match style" if you're going to use TextEdit.

Good luck!

Brian.
Logged

couchjr

  • World Citizen
  • ***
  • Posts: 121
Re: How to generate a list (file) of all values of a tag field in a library?
« Reply #2 on: November 24, 2015, 05:43:20 pm »

Thanks, Brian. So if I understand correctly, this generates a list of the composer field value for all tracks, and then the "~nodup=[Composer]" removes duplicates so that I only get one instance of each composer in the library? And hiding the other columns means they aren't copied using Edit > Copy to the clipboard? Sounds like an elegant solution. I could use BBEdit to do the paste; I think I can control the style there.
Logged

blgentry

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 8014
Re: How to generate a list (file) of all values of a tag field in a library?
« Reply #3 on: November 24, 2015, 05:48:33 pm »

You're correct on all counts!  BBEdit is supposed to be great.  I have Text Wrangler, which is similar from the same company.  Pasting MC copied fields into Text Wrangler works just fine.

Brian.
Logged

Arindelle

  • Citizen of the Universe
  • *****
  • Posts: 2772
Re: How to generate a list (file) of all values of a tag field in a library?
« Reply #4 on: November 25, 2015, 11:17:46 am »

Just another way to go about this ...

When I need to do this I just get a smartlist to display the data that I want then go from the main menu FILE=>EXPORT PLAYLIST.

You can choose HTML or CSV delimited text file depending on your needs -- you can then export either an HTML file or csv txt file,  directly importing that into either a word-like program or into a spreadsheet program. No need for third party reformatting really and I find it quicker than copy/pasting, but both work :)

I only have JRiver on PC, maybe this is not an option for Mac though, not sure.
Logged

blgentry

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 8014
Re: How to generate a list (file) of all values of a tag field in a library?
« Reply #5 on: November 26, 2015, 09:34:53 am »

Yes, export playlist works on MC for Mac, essentially the same as on windows.  In this case it's sort of unnecessary since he only wants one field; cut and paste makes it easy.

But for other purposes the export as CSV is definitely useful.

Brian.
Logged
Pages: [1]   Go Up