INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Problems with Sorting in Current Builds  (Read 2048 times)

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Problems with Sorting in Current Builds
« on: December 15, 2014, 04:01:21 pm »

I'm having some trouble with some of my views and sorting.  Not sure when this started, but I'm having multiple issues with sorting in the current build.  The Category-views specific one (#1) could be just something I don't understand about how it works, but the second one is very oddball.  Basic description is all I can provide right now, but I can do more testing later if you need more:

1. Category Views:

Sorting entered in Set Rules for File Display isn't being applied to the File List in Categories style Views, until you drill down to the "lowest level".
 Here are a couple screenshots that illustrate this issue:

EDIT: I figured this out.  Ignore #1, but I suspect #2 is still an issue (that's actually what convinced me something was broken, and not just that I misunderstood).

This is the setup of my View.  The results are filtered (but not sorted) by the parent View.  The important thing to note is that it has Z-A order for both Season and Episode (causing newest episodes to sort to the top, or they should anyway...



When I open the view and open one of my Series items, I get this:



Notice, the Seasons and Episodes are sorted in normal A-Z order.  Oddly, the Sort Indicator arrow and number in the Column Header lists A-Z by [Name].  But this isn't true either (look at the Names).  I don't know where this order is coming from.  Also, I've tried applying the Sort directly to the view as well, including all of the pre-set values (the screenshot above is using (Default) instead of any specific one), and it seems to make no difference.  This is the only order I can get them to sort in with this view.

Now, when I drill down and open up one of the Seasons, I get:



Which is alright.  But note that in this case, I'm showing none of the Sort Indicator arrows in the Column Headers.

2. Save Changes on List Header Clicks:

Options > Tree & View > Sorting > Save changes on list header clicks doesn't appear to be functional right now, or is behaving normally.  In this case, I have one of my longstanding Panes-style Views.  I always keep the Save changes on list header clicks item DISABLED.  I prefer to set the sort order explicitly in Set Rules for File Display.  This issue is difficult to replicate, but I've seen it a number of times.  I've seen this mostly while playing with the other (Category style View) issue described above, so it might be triggered by playing around with the Sort order functionality there (trying to manually change them and whatnot).

In any case, a number of times since I've been messing with these Views, I've been able to get List Header Clicks to "save" even though I have that option disabled.  Once they're saved, I can't get the View to re-honor my explicitly defined sort order in Set Rules for File Display, unless I:

1. Remove the sort order defined in Set Rules for File Display entirely.
2. Close the dialog to apply the changes.
3. Open the dialog again and re-apply the Set Rules for File Display sort order.
4. Now the view behaves again.

I've tried in this case to mess with the sort order defined in the View Header, but they seemed to be ignored completely.  As I said before, I don't use these, and use sort orders defined in the View Set Rules for File Display itself (which has always worked in the past, and does work in all my other Views).

So, it feels like something is rotten in there.  As I said, item #1 seems like it might just be something I didn't notice before, but if so, how is it supposed to work?  How can I reverse sort that list properly with that kind of View?

And, the other thing just feels very buggy.  It works right sometimes... Even most of the time, but occasionally "freaks out".
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Problems with Sorting in Current Builds
« Reply #1 on: December 15, 2014, 04:27:58 pm »

Okay, I've figured out a little more about Issue #1, and it looks like it is "as designed" (just weird).  The order is dependent on the order the Categories themselves are sorted.  This is a bummer since it sorts [Series] == 0 to the top of the list because Unassigned sorts before assigned fields.  I want untagged episodes to sort below those with explicit [Season] tags, which is how it works if I use a Panes style View.

Hmmm...

Also, the Sort Indicator arrow is still [Name] Ascending, and doesn't change, so that is a bit confusing as well.  But, at least I understand what is happening now.  I suppose I could "fix" it by using a custom Expression field that removes the normal formatting from [Season]...?

I'll do more testing tonight on #2.  I've seen the problem 4 or 5 times between last night and today.  See if I can figure out how to reproduce it reliably...
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

mojave

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 3732
  • Requires "iTunes or better" so I installed JRiver
Re: Problems with Sorting in Current Builds
« Reply #2 on: December 15, 2014, 04:31:44 pm »

I also noted a sort issue today. Maybe related?
Logged

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Problems with Sorting in Current Builds
« Reply #3 on: December 15, 2014, 04:38:15 pm »

I've seen quite a bit of "weird" sorting misbehavior over the past weekend, I'll say that.  I was messing around with Views and moving things around, and it was troublesome.  I had to close and restart MC to get it to behave a few times.

I tried this:

I suppose I could "fix" it by using a custom Expression field that removes the normal formatting from [Season]...?

And I can't get it to work.  Even if I use the expression: [Season, 0] as my second category, it always displays "Unassigned" for items with a blank Season field, and sorts it to the top.  I suspect that's because these are actually blank, not just filled with Zero, since [Season] is a string type field.

Hmmm... How can I get Unassigned to sort last in a Category view, with a Z-A (Descending) Category sort order?
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Problems with Sorting in Current Builds
« Reply #4 on: December 15, 2014, 06:33:21 pm »

I also noted a sort issue today. Maybe related?

I think that might be related, somehow.

Something fishy is certainly going on.  Was anything changed in here recently while I was sleeping?
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Problems with Sorting in Current Builds
« Reply #5 on: December 15, 2014, 09:33:52 pm »

I've played around with it a bit more, and I can't get #2 to recur.  Let's hope it is gone, but I'll keep my eye on it.

For #1, I solved it...  If anyone stumbles on this thread in the future, here's an expression for [Season] that will let you sort "Unassigned" values to the end of the list, even when Sorting Descending.  Instead of adding the [Season] field as the category in the view, instead add an Expression (called "Season" so it looks the same) and then use this expression:

Code: [Select]
If(IsEmpty([Season]),0,[Season, 0])
That way, it'll actually output "0" for empty values, and they'll properly sort to the "end" of a Descending sorted list.

It was a bit counter-intuitive that the categories "override" the sorting saved in the View, but I suppose this makes sense.  You want to make sure the items from a particular Category all sort together, so it applies the sort order for the Category itself on top of the existing sorting, until you've drilled down all the way through the categories.  Confused me for two days.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

ldoodle

  • Galactic Citizen
  • ****
  • Posts: 411
Re: Problems with Sorting in Current Builds
« Reply #6 on: December 16, 2014, 10:00:47 am »

Possible same here: http://yabb.jriver.com/interact/index.php?topic=90662.msg649200#msg649200

From what I can gather it's giving preference to the category library fields sort setting, so in your case Series then Season, which are presumably both Ascending (default), then anything else in you have in Modify Results > Sort by.

So for you it's: Series > Season > Sort by fields

Try changing the Sort setting actually within the Series or Season categories to be descending, as a test.  This is what I did and it's what influences it.
Logged

ldoodle

  • Galactic Citizen
  • ****
  • Posts: 411
Re: Problems with Sorting in Current Builds
« Reply #7 on: December 16, 2014, 10:10:04 am »

It was a bit counter-intuitive that the categories "override" the sorting saved in the View, but I suppose this makes sense.

I'm not sure it does.  I see Categories as how things are grouped and what's actually displayed on screen, and that's all it should be.  They shouldn't then determine the sort order, as per my post in the Features thread, unless there is nothing in Modify Results > Sort by.

In my opinion, the precedence should be the other way round: Modify Results > Sort by should override Sort within a Category.
Logged

Hendrik

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 10791
Re: Problems with Sorting in Current Builds
« Reply #8 on: December 16, 2014, 10:45:55 am »

Grouping Views are intentionally sorted by their grouping category (other information is also not available at this point). The sorting in Modify Result only applies to actual files.

Assume I group by Series but want to sort by Season. Every Series has multiple Seasons below it, so how would it ever sort by that?
It becomes very unintuitive and inconsistent fast, which is why it sorts by the category it groups by, its the only consistent value it has, as every other value could have a million different values in the grouped set.

I'm sorry if this doesn't work in your setup, but alternatives are just inconsistent at best.
Logged
~ nevcairiel
~ Author of LAV Filters

ldoodle

  • Galactic Citizen
  • ****
  • Posts: 411
Re: Problems with Sorting in Current Builds
« Reply #9 on: December 16, 2014, 11:07:20 am »

I think I'm getting confused somewhere.

As per screenshots.  This is what I'm referring to (first screenshot).  The Sort options for a category are based on a built-in list.  Can this list not be changed to a pick-list of all available library fields?

In terms of say DVD/Blu-ray rips, what constitutes a file?

So in my case, I have Series and Name categories (red box, second screenshot).  When I'm in the 'All' view in Theater View, it's showing me all my films as 'files', right?  Or am I only viewing 'files' once I navigate inside the Name category.

So if I add a Sort by rule in Modify Results, to say sort by Series (z-a), it still shows them in a-z order because my Series category is set to Ascending (third screenshot).

Based on what you said, it should detect the Sort by rule in Modify Results because they're files, but it isn't.
Logged

Hendrik

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 10791
Re: Problems with Sorting in Current Builds
« Reply #10 on: December 16, 2014, 11:16:48 am »

Files are those views that when you select an item, it shows the file detail panel on the right in Theater View.
If you use a grouping of any kind on that level, its not actual files, but grouping entries - even if all of them auto-zoom directly to the file once selected.
Logged
~ nevcairiel
~ Author of LAV Filters

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Problems with Sorting in Current Builds
« Reply #11 on: December 16, 2014, 12:08:25 pm »

Possible same here: http://yabb.jriver.com/interact/index.php?topic=90662.msg649200#msg649200

From what I can gather it's giving preference to the category library fields sort setting,

Yes.  That's exactly what I explained above.

It does make sense in some ways, from an ease of use perspective.  The vast majority of users who build these kinds of views would probably prefer the current behavior, because it automatically "fixes" the sorting to match the generally expected results (that the currently displayed category sorts those together).

It is just when you're trying to do something fancy with it that it gets a bit confusing.  I'm not saying this is necessarily the best system, but it does make sense why they did what they did.

But, yes, what happens is:

* Sorting defined in the View itself (via the View Header or in the File Search) is applied.
* Then, the sorting for each Category is applied over top of your sort order.

I'm confused by some of Hendrik's comments above, mainly because I think he is using the term "grouping" when he really means "categories".  Sorry, Hendrik, though "groupings" are a thing in MC, which work differently, so it is getting somewhat confusing.  I assume you mean categories, based on the background here, and other details.

But, if you're talking about "real" Grouping (as-in, the inline groups within the file list), well... I'm confused, and I do wish for some sorting-related changes there.  I wasn't talking about my frustrations with the Grouping system in this thread, though, so...  ?

Here, it is fine, and I understand it now.  I have only two minor pieces of feedback on the way this (category view sorting following the category):
* The onscreen feedback (the Sorting Indicator Arrows) should make sense or be omitted.  Right now, [Name] gets the indicator and that's wrong.
* It would be nice if "Unassigned" sorted the same as other blank values (to the end of the list) in MC, even though the actual Category shown is called "Unassigned".  Right now, it looks like these actually sort with "U" which makes no kind of sense, and is confusing in a file list.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

ldoodle

  • Galactic Citizen
  • ****
  • Posts: 411
Re: Problems with Sorting in Current Builds
« Reply #12 on: December 17, 2014, 03:51:31 am »

Files are those views that when you select an item, it shows the file detail panel on the right in Theater View.

Ah OK, that explains it.

So in my case, the Series category isn't actually showing files, because it's being 'grouped' by Series, by way of having the Series category.

I think I should be able to work around it by not having any categories, which would then show a flat list of 'files', which I can then sort using Modify Results.

But that's if I wanted a flat list, rather than having each film in a series 'grouped'.
Logged
Pages: [1]   Go Up