Sort Key numerically or alphabetically based on selected Key Format

Device model : iPad Air 2024 M2
Version of operating system : iOS 17.7
Version of djay : 5.2.4
Hardware/controllers used : Reloop Mixtour Pro

Summary of the issue: I’ve got a particular Smart Playlist of 173 songs, and I’m using Numerical Key (1a/1B) format for my Key tag. Based on the good range of tracks I have in that list…

If I sort the playlist by Key Ascending I will see tracks in this order:

8B, 8A, 9B, 9A, 10A, 11A, 12A, 1A, 2A, 3B, 3A, 4B, 4A, 5B, 5A, 6B, 6A, 7B, 7A

If I switch the sort to Key Descending I will see the reverse order:

7A, 7B, 6A, 6B, 5A, 5B, 4A, 4B, 3A, 3B, 2A, 1A, 12A, 12B, 11A, 10A, 9A, 9B, 8A, 8B

How to reproduce the issue: The issue is common across all playlist/library listings.

It’s really off-putting, given that the Key tag is written there by Djay during its analysis it’s not possible (nor would I want to!) mess about with the tags. It should be in numerical and the alphabetical order. (And no comments please about using “0” to make (0)1A come first, nothing else does it that way!)

Sort by Key Ascending should be in this example:

1A, 1B, 2A, 3A, 3B, 4A, 4B, 5A, 5B, 6A, 6B, 7A, 7B, 8A, 8B, 9A, 9B, 10A, 11A, 12A

Sort by Key Descending should be in this example:

12A, 11A, 10A, 9B, 9A, 8B, 8A, 7B, 7A, 6B, 6A, 5B, 5A, 4B, 4A, 3B, 3A, 2A, 1B, 1A

Thanks very much.

Kind regards,

James

It’s sorting by key, not by number. The number only represents the actual music key.

By your reckoning, Abm should be first, followed by B, then Ebm. Why? What kind of key order is that?

Musically it should go C, Db, D, Eb, E, F, F#, G, Ab, A, Bb, B - which is:
8B, 3B, 10B, 5B, 12B, 7B, 2B, 9B, 4B, 11B, 6B, 1B :grinning:

It’s the Numerical Key format which is an option in Djay - it’s also how Mixed in Key format is displayed.

I don’t use “Musical Key” format but if I did then in my example that list for Key Descending would be:

F, Bb, Eb, Ab, Db, Gb, B, E, A, D, G, C

This isn’t “sorted” in any particular order either, but that’s not the point…

The sort order for Numerical Format should be 1-12 asc and 12-1 dsc. Then, for each number you have either “A” or “B” tracks.

This is all based on the Camelot Key wheel.

Strictly speaking, both your way and the way it’s ordered in djay Pro are “wrong” - because neither are sorting by key (which is how it’s labelled). If you want it to be sorted based on what number comes first, then it should be called “sort by Camelot number” because it’s not in key order.

Musically, there’s nothing wrong with starting at C, which is 8B.

Hi,
My perspective as a user would be -when using and showing the Camelot notation- I would expect the sorting to be directly based on these numbers, both ascending and descending.

In general, any sorting in software —wherever it’s applied—should conform to the value being displayed, following commonly accepted standards. For example, alphabetical sorting (A, B, C) or numerical sorting (1, 2, 3).

So I agree with @James_Gillies on this point—when the Camelot notation is shown, sorting should logically follow that system, not the underlying traditional key order.

In that case, then it should not be called “sort by key”, but maybe “sort by compatibility”.

Even by the Camelot system, listing by number then letter is not correct unless you’re using fuzzy key mixing. OK if you think 1A should be first and then 1B, the relative major - but then going to 2A is “wrong”.

The original Camelot system says to go from 1B to 2B, not 2A. Adhering to the (non fuzzy) system, it should go 1A, 1B, 2B, 2A, 3A, 3B and so on - alternating between major and minor. No diagonal moves.

Following “commonly accepted standards”, sorting by key should start with C and go up in tones or semitones.

In this scenario the “Key” is just the field name, nothing more. The notation used should be honoured when stating an ascending or descending sort order, as with any other field (in a database).

Unfortunately, I am not and never will be skilled enough to be a true musician, so I have to rely on things like the Camelot system to be able to mix (easily) harmonically.

Sorting alphanumerically would just be the way any field is sorted when labelled as numbers and letters.

On another point about transitioning from (for example 1B to 2B instead of 2A) I don’t disagree with you but the vast majority of my tracks are “A” tracks (Major I presume in the main?) and very few are “B” tracks (Minor I presume in the main?) - as such whenever I come across a new “B” track for my collection it’s quite exciting as there’s an opportunity for a slightly different sound to be introduced into the mix.

Now I’m not making excuses for my lack of musical academia, what I’m saying is that in my real world of mixing mainly House genres there’s simply not enough “B” tracks to go around around to transition that way, so “diagonal” harmonic mixing needs to be explored on a case-by-case basis. And most often, you’ll be OK - as long as you use your ears to check for an obvious clash in harmonies - or just mix in/out with percussion only as a last resort.

Hi @James_Gillies, this is currently expected behavior in djay. However, I have changed this from a Bug Report to a Suggestion and adjusted the title accordingly. I have forwarded this to the dev team for consideration. In the meantime, please use the blue Vote button at the top left of this page so we can gauge user demand for this feature.

Everyone, please feel free to share additional details on how you think sorting should be handled when the different Key formats are selected. Thanks!

@James_Gillies you have A and B reversed. A is minor, B is major.