Custom Nodes for MMW5/2024+

Get help for different MediaMonkey v5 / v2024 Addons.

Moderators: jiri, drakinite, Addon Administrators

RiffRaffAK
Posts: 27
Joined: Thu Feb 23, 2012 12:11 pm

Custom Nodes for MMW5/2024+

Post by RiffRaffAK »

How do you configure Custom Nodes in MMW5? The only options I have after installing are: Show Pop & Rock genres
or
Show 5 most played tracks.

None of these are what I need. Specifically, I am trying to configure a Music Subnode for Complete Albums. Can anyone help with this?
Barry4679
Posts: 2446
Joined: Fri Sep 11, 2009 8:07 am
Location: Australia
Contact:

Re: Custom Nodes for MMW5

Post by Barry4679 »

RiffRaffAK wrote: Fri Jul 22, 2022 7:08 pm How do you configure Custom Nodes in MMW5? The only options I have after installing are: Show Pop & Rock genres
or
Show 5 most played tracks.

None of these are what I need. Specifically, I am trying to configure a Music Subnode for Complete Albums. Can anyone help with this?
You mentioned both nodes and sub-nodes in your query. Which of these are you wanting to create?
Firstly let's agree on the definition of "subnode" .... is it #1 or #2 in this diagram ?

FWIIW #1 is a node (aka Collection), and #2 is a sub-node.

If you asking about #2, there is no way to create a custom sub-node in MM5.
That would need to handled by a Add-on,. There was one in MM4 (MagicNodes), but I am not aware of any that could do that for you in MM5 atm

Creating a new node is simple to achieve, but it requires the Gold Version of MM5, ie. not the free version.
How it works is documented here.
The instructions are sketchy. Ask again if you need more assistance.
Want a dark skin for MM5? This is the one that works best for me .. elegant, compact & clear.
Erwin Hanzl
Posts: 1190
Joined: Tue Jun 13, 2017 8:47 am
Location: Vienna

Re: Custom Nodes for MMW5

Post by Erwin Hanzl »

MM 5.0.4.2657 Alpha
by RiffRaffAK » 23 Jul 2022, 02:08
How do you configure Custom Nodes in MMW5?
One access: TOOLS> Options> Library>Collections and Views
Double click on your collection (Music)
Then on the Sub-Nodes tab - here you can select from the available nodes and also change the order in the view.

Image
MMW 4.1.31.1919 Gold-Standardinstallation
Ludek
Posts: 5122
Joined: Fri Mar 09, 2007 9:00 am

Re: Custom Nodes for MMW5

Post by Ludek »

Re the custom nodes addon, AFAIK currently there is only the customNodes sample script (copy it from sampleScripts to scripts folder) where you can define custom nodes like this: https://www.dropbox.com/s/zz72gh529883r ... 4.png?dl=0
rusty
Posts: 9058
Joined: Tue Apr 29, 2003 3:39 am
Location: Montreal, Canada

Re: Custom Nodes for MMW5/2024+

Post by rusty »

fyi, the addon was updated awhile ago to include the ability to easily add/remove/same nodes from within the UI.

It's included in the MediaMonkey 2024 sample scripts directory but for convenience, is also available at: https://www.mediamonkey.com/addons/brow ... tom-nodes/

Please share your favorite node queries!

-Rusty
sonos
Posts: 203
Joined: Wed Aug 07, 2013 11:54 am

Re: Custom Nodes for MMW5/2024+

Post by sonos »

How do I manage a SQL query in Custom Nodes (e.g., especially for recurring queries) to get output in a separate window?
Example

Code: Select all

SELECT Strftime('%Y/%m/%d %H:%M:%S', ( Julianday(playdate) + 2415018.5 ),
       'localtime')
       AS plays
FROM   played AS p
       JOIN songs AS s
         ON s.id = p.idsong
WHERE  album = 'Kristallen'
       AND songtitle = 'The Wedding';
Image

Carsten
IanRTaylorUK
Posts: 621
Joined: Fri Dec 27, 2019 4:41 pm

Re: Custom Nodes for MMW5/2024+

Post by IanRTaylorUK »

rusty wrote: Tue Dec 30, 2025 2:00 pm fyi, the addon was updated awhile ago to include the ability to easily add/remove/same nodes from within the UI.

It's included in the MediaMonkey 2024 sample scripts directory but for convenience, is also available at: https://www.mediamonkey.com/addons/brow ... tom-nodes/

Please share your favorite node queries!

-Rusty
https://www.dropbox.com/scl/fi/hvt42dp1 ... vykqs&dl=0

A selection a new nodes (and the original ones) that have been briefly checked in SQL Editor and then in Custom Nodes 1.1.5. Some are very specific to how I work with my library, but thanks to the new Custom Nodes you can easily edit the SQL.

My favorite at the moment is Missing NOT in Tag OR File. This refers to Artwork and my convention of only having a single front cover stored in both the tag AND stored (as folder.jpg or sometimes albumart.jpg).
Ian Taylor
sonos
Posts: 203
Joined: Wed Aug 07, 2013 11:54 am

Re: Custom Nodes for MMW5/2024+

Post by sonos »

Thank you for your reply.

In my example, instead of a list with dates and corresponding times, only the main window with the specified MM fields such as composer, album artist, etc. is displayed.

I would like to see an output like in the addon SQL without having to re-enter the entire query. In my example, you would only need to change album = ‘Kristallen’ AND songtitle = ‘The Wedding’.
IanRTaylorUK
Posts: 621
Joined: Fri Dec 27, 2019 4:41 pm

Re: Custom Nodes for MMW5/2024+

Post by IanRTaylorUK »

I see SQL Editor (https://www.mediamonkey.com/addons/brow ... ql-editor/) as a developer SQL test tool. It does not necessarily return ALL the hits (limited to about 1000) but it does give some feedback about the time taken - which is quite useful.

On the other hand, Custom Nodes 1.1.5 (https://www.mediamonkey.com/addons/brow ... tom-nodes/) does save the SQL and can therefore be used to edit. It does return ALL hits and seems to me to be quicker.

Another thing you might want to do is use an Editor to keep your SQL. For example, EditPlus can be set-up to display the SQL colour coded the same as the Media Monkey 2024 SQL Editor add-on using a syntax file. The "syntax" file can be set up to apply to - for example - file with the extension .sql and .mcnc.

Hope this helps.
Ian Taylor
changewand
Posts: 6
Joined: Sat Oct 08, 2011 9:20 pm

Re: Custom Nodes for MMW5/2024+

Post by changewand »

Has anyone developed a custom node to find tracks with the same artist/title/track #?
IanRTaylorUK
Posts: 621
Joined: Fri Dec 27, 2019 4:41 pm

Re: Custom Nodes for MMW5/2024+

Post by IanRTaylorUK »

If we take my SQL 004 for duplicates:

Code: Select all

SELECT Artist, SongTitle, COUNT(*) as Occurrences
FROM Songs
GROUP BY Artist, SongTitle
HAVING Occurrences > 1
ORDER BY Artist ASC;
and add TrackNumber, we get:

Code: Select all

SELECT Artist, SongTitle, TrackNumber, COUNT(*) as Occurrences
FROM Songs
GROUP BY Artist, SongTitle, TrackNumber
HAVING Occurrences > 1
ORDER BY Artist ASC;
but this SQL does not deal with the legitimate situation where by you have two "overlapping" albums with the same Artist.
Ian Taylor
IanRTaylorUK
Posts: 621
Joined: Fri Dec 27, 2019 4:41 pm

Re: Custom Nodes for MMW5/2024+

Post by IanRTaylorUK »

The Purpose of This Query
The primary purpose of this SQL script is to identify track number collisions within your music collection (specifically TrackType 0). Unlike a simple duplicate file finder, this query detects "logical duplicates"—instances where two or more distinct song entries are competing for the same position on the same disc of an album. By excluding SongTitle from the grouping logic, it specifically flags data entry errors where different songs have been accidentally assigned the same track index. This allows you to maintain a clean, chronologically accurate library, ensuring that media players and library managers sort your albums correctly without overlapping or missing tracks.

Code: Select all

SELECT 
    TrackType, 
    AlbumArtist, 
    Artist, 
    Album, 
    DiscNumber, 
    TrackNumber, 
    SongTitle, 
    COUNT(*) as Occurrences
FROM Songs
/* Filter: Only include 'Music' (Type 0). 
   This excludes Podcasts, Videos, and Audiobooks automatically. */
WHERE TrackType = 0  
/* Logic: Define what makes a 'duplicate'. 
   We group by Album and Track details, but NOT SongTitle.
   This catches two different songs assigned to the same track number. */
GROUP BY 
    AlbumArtist, 
    Album, 
    DiscNumber, 
    TrackNumber
/* Filter results to show only the collisions (where count is 2 or more) */
HAVING Occurrences > 1
/* Sorting: Prioritize the worst offenders (highest Occurrences) first, 
   then organize alphabetically using your custom IUNICODE collation. */
ORDER BY 
    TrackType ASC, 
    Occurrences DESC, 
    AlbumArtist COLLATE IUNICODE, 
    Album COLLATE IUNICODE, 
    DiscNumber COLLATE IUNICODE,
    TrackNumber COLLATE IUNICODE;
    
Ian Taylor
Post Reply