Saving Artist-related data

Post a reply

Smilies
:D :) :( :o :-? 8) :lol: :x :P :oops: :cry: :evil: :roll: :wink:

BBCode is ON
[img] is ON
[url] is ON
Smilies are ON

Topic review
   

Expand view Topic review: Saving Artist-related data

Re: Saving Artist-related data

by Peke » Thu May 02, 2019 9:09 pm

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.

Re: Saving Artist-related data

by GbMedusa » Thu May 02, 2019 12:17 pm

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.

Re: Saving Artist-related data

by Peke » Mon Apr 29, 2019 5:42 pm

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.

Re: Saving Artist-related data

by Lowlander » Mon Apr 29, 2019 1:25 pm

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.

Saving Artist-related data

by GbMedusa » Mon Apr 29, 2019 1:12 pm

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.

Top