How to control multiple subreport from a tablix

Ali Ahad 91 Reputation points
2023-03-20T04:21:01.0533333+00:00

I got a tablix where I am displaying 9 different reports.

ssre_tablix

Users wants to click on months to review the raw data of the report for that reporting month. I have created 9 different sub reports to show that. Each sub report columns are different so I cannot use Union All to combine all sub reports datasets into one.

I looked online and it looks like either I have to user SWITCH expression but I am not understanding how can I control different sub reports.

Thanks,

Ali.

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,813 questions
{count} votes

1 answer

Sort by: Most helpful
  1. AniyaTang-MSFT 12,321 Reputation points Microsoft Vendor
    2023-03-20T05:58:32.41+00:00

    Hi @Ali Ahad

    Do you mean that you want to jump to the corresponding subreport when you click on the month?

    Then you can click "Text Box Properties->Action->go to report", and then fill in the expression in specify a report.

    It is really necessary to use the Switch function. The following is an example of the expression I wrote. It means that when the month is 1, jump to the chart report of the corresponding path, and when the month is 2, jump to the image report of the corresponding path. You More conditions can be added.1

    I set the font of the text box to be blue and underlined to distinguish it. Preview, when I click February, it jumps to another report.

    2

    3

    For detailed usage of the Switch function, you can refer to this link: https://learn.microsoft.com/en-us/sql/reporting-services/report-design/expression-examples-report-builder-and-ssrs?view=sql-server-ver16#DecisionFunctions.

    If the answer is helpful, please click "Accept Answer" and upvote it. If you have any questions, please feel free to let me know.

    Best regards,

    Aniya