changing which column is primary, secondary etc in ssrs interactive sorting

db042190 1,516 Reputation points
2022-09-12T11:23:39.303+00:00

Hi we run 2014 but will be on 2019 in the coming months.

I cannot locate an old post i created on this subject and could not recall the answer i was given .

I don't think this is a row group question. There is no dynamic nature to the format that is rendered in the theoretical report which has one row per client and ten amount columns across.

We all know how to create interactive sorting in ssrs, the feature that renders up and down arrows which the user can use to sort his data.

Most of us know what a primary sort column is, a secondary sort column etc. The question is simply this. My user wants to sort ascending on amount 3 (primary), descending on amount 4 (secondary) and ascending on amount 5 (tertiary). So he hits the arrow on amount 3 etc and then runs the report. Has ssrs remembered the order in which he hit the arrows? Now he wants amount 5 descending (primary), amount 4 ascending (secondary) and amount 3 descending (tertiary). So he hits those arrows accordingly in that sequence and renders the report. Has ssrs remembered that those were the only up and down arrows he hit and in what sequence they were hit?

Or is ssrs going more on a left to right scheme not really caring about the arrows just hit by the user but instead the final look of what the arrows say to do. If ssrs is remembering what arrows were hit most recently, is it then using the previous choices on all the other columns in any of its sorting decisions? Also, if it is remembering what arrows were hit most recently and giving those priority over all other arrows, is there some limit on how may columns it can remember as being hit and in what sequence between renderings?

SQL Server Reporting Services
SQL Server Reporting Services
A SQL Server technology that supports the creation, management, and delivery of both traditional, paper-oriented reports and interactive, web-based reports.
2,913 questions
{count} votes

Accepted answer
  1. AniyaTang-MSFT 12,441 Reputation points Microsoft Vendor
    2022-09-13T05:45:54.217+00:00

    Hi @db042190
    When interactive sorting is enabled, the first click of the interactive sort button will sort items in ascending order, and a second click will change to descending order. If you want to remember a previously existing sort, you can hold down the Shift key and sort another column.
    For example, if you want to sort by amount 3 (primary) ascending and then by amount 4 (secondary) descending, then you can do the following:

    1. Click the amount 3 icon once;
    2. Hold down the Shift key, click the amount 4 icons twice.
      Best regards,
      Aniya
    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. db042190 1,516 Reputation points
    2022-09-13T11:39:50.127+00:00

    thx aniya. why twice on amount 4? because the shift key is involved in the 1st click? and also, what if there is a third column? shift key again click, and then click again on 3rd col? and do all the other sortable cols still play a sort of passive role in what to sort on 4th, 5th etc? perhaps from left to right? or not at all? also if amount 4's current sort order of "up" (ie ascending) is to act as secondary, just shift click its icon once?


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.