Interactive Sorting to a Table in SSRS



Interactive sorting is one of the beautiful option given by Microsoft in SSRS. This is really beautiful because to implement similar kind of functionality in a PROGRAMMING language I spent one week in year 2005. So I love this option. By enabling this option, user can toggle between Ascending and Descending order of the rows in a table report. We can play in different ways using the same option in Matrix format like ordering rows and columns. This feature is supported only in rendering formats that support user interaction, such as HTML.

This option can be set to any “TEXT BOX” in the report. But in table reports it suits better if you enable this option on column headers. Let’s see the steps involved in enabling Interactive sorting in a table format report.

I have created a report with a table format and PFB the preview of the report.

Now lets see the steps involved in enabling the sorting for the column “Color”.

  • Go to the design and right click on the Color column header as  shown below and select TextBox Properties option.

  • Select Interactive Sorting page and check the checkbox “Enable Interactive Sorting on this text box”.

  • As this is Table report format, we will not have any groups and hence leave the Detail rows option as it and set Sort By option to the column by which you wish to sort the rows. In this case I am going with color column.

  • Click OK and Preview the report. You can find Double Arrows on the column header COLOR as shown below.

Repeat the above steps if you wish to add the same for other columns too. The first time you click an interactive sort button, items are sorted in ascending order. Subsequent clicks toggle the sort order between ascending and descending order.

Try it and enjoy !!

Roopesh Babu V