Saving Artist-related data

Get answers about using MediaMonkey 4 for Windows.

Moderator: Gurus

GbMedusa
Posts: 3
Joined: Thu Oct 03, 2013 3:31 pm

Saving Artist-related data

Post by GbMedusa »

Is it possible to attach a property to an artist? I want to track whether an artist's name should be reformatted for sorting (firstname lastname > lastname, first name).

I am trying to clean up my library with a script I am working on (self-made). One of the first things is checking whether I want to have the name reformatted for sorting. Right now, I'm using one of the custom fields for a "yes" or "no" response. However, this doesn't "stick" to the artist, so I have to do it every time.

I got excited when I saw there was a "Artist.Comment" property https://www.mediamonkey.com/wiki/index. ... t::Comment for scripting, but it looks like it hasn't been implemented.

If it can't be done internally, any suggestions for tracking externally? Something that can be controlled with MM's VBscript.

Thanks.
Lowlander
Posts: 56570
Joined: Sat Sep 06, 2003 5:53 pm
Location: MediaMonkey 5

Re: Saving Artist-related data

Post by Lowlander »

You can right click on an Artist in the Media Tree under the Artist, Album Artist and Artist and Album Artist nodes and select Properties to access comments for Artists. However this is the only place to access it in the interface.
Peke
Posts: 17484
Joined: Tue Jun 10, 2003 7:21 pm
Location: Earth
Contact:

Re: Saving Artist-related data

Post by Peke »

Hi,
If you refer to https://www.mediamonkey.com/wiki/index. ... =SDBArtist then it should be fairly easy to create Tree node https://www.mediamonkey.com/wiki/index. ... le=SDBTree and https://www.mediamonkey.com/wiki/index. ... DBTreeNode with filtered Artist comments especially as you can directly execute DB Commands using https://www.mediamonkey.com/wiki/index. ... DBDatabase to filter non empty "Artist.Comment" property.

Also you can create your own table in Database for internal use.
Best regards,
Peke
MediaMonkey Team lead QA/Tech Support guru
Admin of Free MediaMonkey addon Site HappyMonkeying
Image
Image
Image
How to attach PICTURE/SCREENSHOTS to forum posts
GbMedusa
Posts: 3
Joined: Thu Oct 03, 2013 3:31 pm

Re: Saving Artist-related data

Post by GbMedusa »

I've gotten this far but keep getting a syntax error.

Code: Select all

dim strSN : strSN = "Sorted Artist Name: "
SQL = "UPDATE Artists SET Artists.Comment = '" & strSN & "' WHERE Artists.Artist = '" & itm.Artist.Name & "'"
SDB.database.execSQL(SQL)
Any suggestions? I'm trying to write to the Artist's Comment (field? database entry?), not just read its contents.

Thanks.
Peke
Posts: 17484
Joined: Tue Jun 10, 2003 7:21 pm
Location: Earth
Contact:

Re: Saving Artist-related data

Post by Peke »

Why are you using SQL to Write use https://www.mediamonkey.com/wiki/index. ... ists::Item same approach would be directly editing from https://www.mediamonkey.com/wiki/index. ... DBSongData on Track I suggested SQL to Query for Artists with non empty Artists comment where you can easily SDBArtists::Item to get to data for editing.
Best regards,
Peke
MediaMonkey Team lead QA/Tech Support guru
Admin of Free MediaMonkey addon Site HappyMonkeying
Image
Image
Image
How to attach PICTURE/SCREENSHOTS to forum posts
Post Reply