Do you guys use the "Sorting and Grouping" box for Access report design? I'm wondering how this runs up against what you put in the query design view. I'm hoping that I can avoid exhaustive testing if someone else (you!) is already strong on it. Can you confirm or refute the "THEORY" below?
Note that this isn't worrying with pure SQL; just the ACCESS interfaces for queries and reports.
Let me postulate an answer, and if anyone can augment or correct this, great. I'm not saying that this is correct, but it's my inclination currently:
*********THEORY*********THEORY*********
1. Call the Report sorting and grouping box "S&G". S&G sorts (i.e., its right column) rank supreme. The first shown S&G line is done first (even if not visible). Note: every S&G item is _required_ to have asc. or desc. sort order.
2. Remaining S&G lines are processed, from top to bottom. Thus, a repeated one serves no purpose at all. (I'm starting to get quite bold here - please load your arrows, because I want the correct answer, more than to be right!).
3. *Within* each of those report groups, the query interface's explicit sorts are evaluated, left to right. I.e. the leftmost is done first, and the next one is secondary to it, etc.
4. Query Group Bys are evaluated after the sorts, each implying Ascending.
5. Whatever remains can not be guaranteed to consistently follow any order, even if the table source was sorted.
Orrrrr .... shall we get funky and say 3. The query's sorts & groups are simply ignored and discarded by the report. (BION, this is my vote)
*********THEORY*********THEORY*********
Your time and help is much appreciated.
Note that this isn't worrying with pure SQL; just the ACCESS interfaces for queries and reports.
Let me postulate an answer, and if anyone can augment or correct this, great. I'm not saying that this is correct, but it's my inclination currently:
*********THEORY*********THEORY*********
1. Call the Report sorting and grouping box "S&G". S&G sorts (i.e., its right column) rank supreme. The first shown S&G line is done first (even if not visible). Note: every S&G item is _required_ to have asc. or desc. sort order.
2. Remaining S&G lines are processed, from top to bottom. Thus, a repeated one serves no purpose at all. (I'm starting to get quite bold here - please load your arrows, because I want the correct answer, more than to be right!).
3. *Within* each of those report groups, the query interface's explicit sorts are evaluated, left to right. I.e. the leftmost is done first, and the next one is secondary to it, etc.
4. Query Group Bys are evaluated after the sorts, each implying Ascending.
5. Whatever remains can not be guaranteed to consistently follow any order, even if the table source was sorted.
Orrrrr .... shall we get funky and say 3. The query's sorts & groups are simply ignored and discarded by the report. (BION, this is my vote)
*********THEORY*********THEORY*********
Your time and help is much appreciated.