I am not sure, but I think that it would be better if use Bex's Playlist in Main Window add-on for this. If you decide to stay with RegExp, you could use the mentioned preset as you described, but with it you need to enter playlists names manually. However, here are settings for presets which will assign playlists names automatically:Emrik wrote:I want to add the name of the playlist in the comment field
My intention was to use Preset 135 : Add "(Live)" to the end of Title and modify it so that Live=playlist name (I will type the playlist name each time myself) & field = Comment.
Preset: Assign names of contained playlists to <Into Field>...
Find what: ^.*
Into: Comment
Regular expression 1: checked
Replace with:
Code: Select all
SQLQuery("SELECT group_concat(PlaylistName, '<String Caption="Separator" Value="; ">') FROM PlaylistSongs INNER JOIN Playlists ON PlaylistSongs.IDPlaylist = Playlists.IDPlaylist WHERE PlaylistSongs.IDSong = " & oSongData.ID & " GROUP BY IDSong")
After adding this preset, you could start it using Edit / Assign names of contained playlists to <Into Field>... This dialog is much simpler then the RegExp Find and Replace dialog box and allows you to choose just destination field and separator between playlists names. You understand that each track could be contained in several playlists, right?
I am not sure that you could use simple copy method, because rating values are different. Ratings in MM are from 0 to 100, and I think that iTunes has ratings between 0 and 10. So, you need to use Replace with: Round(oSongData.Rating / 10). If you want to copy rating only for rated tracks, you could use something like: IIf(oSongData.Rating = -1, "$&", Round(oSongData.Rating / 10)) (instead of $& you could enter value which iTunes use for undefined rating).Emrik wrote:i will also use the grouping field to put the MM ratings as grouping field also exist in Itunes Mac so i could then convert grouping field in Itunes Ratings.