Submitted by DavidF on 2016/05/14 16:37
hi,
 
I'm having problems getting subitems sorted the way I want them.
 
What I'm starting off with is a grid (Bibliography) showing books as TLI, with chapters as subitems.Some of these chapters/subitems have an entry in the Code field:
 
 
I then have a grid, Code, that shows only items with something in the Code field:
 
 
Note how the order of subitems has changed. I could not work out what the basis for this ordering could be, then I added the IDItem column. Is it just coincidence that the subitem order corresponds to IDItem order?
 
Anyway, I cannot get the subitems to sort in any other way. In the "original" grid, Bibliography, they are nicely arranged by chapter order - 01, 02, 03 etc - but that is just because that was the order in which I entered them. If I manually move them around, I cannot then get them to sort themselves alphabetically. In both these grids, the only way I can order the subitems is manually: either by the order in which I entered them, or by manually moving them around. Frankly as I anticipate having a lot of subitems in the Code grid, that would be a real pain.
 
There seem to be multiple places where you can determine sorting, and specify that it apply to subitems. These are the ones I have tried:
 
In the Source/Sort bar:
 
 
From the Grid menu:
 
 
And from right-clicking on the sub-items:
 
 
None of these have any effect. Is there no way of having subitems automatically sort in a specified way in a given grid?
 
-- David F.

Comments

Hi David,
 
I'm in a bit of a rush, but 2 things comes to mind:
  1. To see if your sorting works, it is best to switch to flat view first, as hierarchy can sometimes get in the way of sorting
  2. In your last image, to sort sub-items, you must right-click on the parent item, not the first child
HTH !
 
Pierre_Admin
IQ Designer
 

I'm not sure why you're having problems, but I notice that in one case you're displaying context
 
 
but to add to what Pierre said, you could :

1. Remove all automatic sorting ("None, manual" -- see your fourth  screenshot), since you have nothing in your sort box filter (according to your third screenshot)

2.  Use the source bar to sort your items by using the item field as the sort field (since your items seem to be nicely numbered). Just add the item field to the sort box at the right end of the source bar : item
(item desc : will sort descending -- see the help file)
2.1.  if you want to also sort sub items by their item field values, check "sort items and subitems" (your 3rd screen). You can also add a different filter for sub items by separating filers by a vertical bar : filterForTLI | filterForSLI
 
3 If you don't like to use the "source bar" way, you could use one of the other ways, like the sort bar, and use the column header. It works well too.

-
IQ geek
Windows 8.1
CPU: Intel i5 2.6ghz

DavidF

2016/05/14 19:49

In reply to by Armando

Thanks, Pierre and Armando. Seems kind of obvious now, you should use the Sort Bar to sort things... in my defence though I would say that to someone just rummaging around within the interface for "Sorting", it's pretty heavily signalled in the various menus and right-clickings I put in my screenshots, rather than in the actual Sort Bar. Also, the way the manual tells you to use the Sort Bar doesn't work (clicking and dragging the columns) - unless I've missed something.
 
Basically, typing in the relevant column name(s) to the Sort Bar gave me the persistent sort order I was looking for. Without that, the various column/right-clicking/menu options let you set various sort orders, but nothing that survives new items arriving in the grid and the resultant need to refresh. With that, the sort order sticks, and works regardless of display options. Though the points about Context, Flat Display etc were very useful. I understand the database aspect of IQ pretty well I think - it's usually the outlining part that trips me up. 
 
-- David F.

Armando

2016/05/14 20:24

In reply to by DavidF

[quote=DavidF]
Thanks, Pierre and Armando. Seems kind of obvious now, you should use the Sort Bar to sort things... in my defence though I would say that to someone just rummaging around within the interface for "Sorting", it's pretty heavily signalled in the various menus and right-clickings I put in my screenshots, rather than in the actual Sort Bar. Also, the way the manual tells you to use the Sort Bar doesn't work (clicking and dragging the columns) - unless I've missed something.
 
Basically, typing in the relevant column name(s) to the Sort Bar gave me the persistent sort order I was looking for. Without that, the various column/right-clicking/menu options let you set various sort orders, but nothing that survives new items arriving in the grid and the resultant need to refresh. With that, the sort order sticks, and works regardless of display options. Though the points about Context, Flat Display etc were very useful. I understand the database aspect of IQ pretty well I think - it's usually the outlining part that trips me up. 
 
-- David F.
[/quote]
 
I had a look at the online manual and it's pretty up to date. That said I think it should probably differentiate more clearly between automatic and manual sorting,  and between temporary and "permanent" sorting. The current structure doesn't make those distinctions, so it's not very obvious  Otherwise, the info seems correct. 
 
The sort bar is one thing, the source item sort (through the sort box in the source bar) is another.
 
When you're sorting using the sort bar (one of the sort options), you'll first see a grey area over the column hearders and, yes, you can drag & drop the columns to that area (and drag them out to remove them). The drag/drop thing helps when you need to have multiple sorting layers.
 
As for the sort text box in the source bar, it's database oriented and it sorts in the query every time you refresh. (You can have more complex sort filters like : item, check, somethingElse)
 
(then there's the grouping by sort columns, etc.)
 
Maybe "temporary" sortings (in context menus) should be indicated more clearly. Something like "Temp sort item ascending". Also, maybe the tooltips for those temp sort could give indications about the other more "permanent" sort options. 
 
-
IQ geek
Windows 8.1
CPU: Intel i5 2.6ghz