SSRS Preview Picks Wrong Column Items

SQL_Is_Good 156 Reputation points
2021-03-23T13:43:36.597+00:00

Visual Studio 2017

Setup:

Parameter: COMPLEX

DataSource: 1

Datasets: Stored Procedure A, Stored Procedure B

Parameter picks the Apartment Complex Names from SP A, while SP B provides address info for rest of the report.

Problem: I choose the Apartment Complex Names in the PREVIEW, and next I click on View the Report button. The result is showing wrong apartment complex names,

the names that I did not choose. Any help would be appreciated.

Thanks.

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,102 questions
No comments
{count} votes

2 answers

Sort by: Most helpful
  1. ZoeHui-MSFT 18,896 Reputation points Microsoft Employee
    2021-03-24T07:19:47.547+00:00

    Hi @SQL_Is_Good ,

    The issue is a little hard to narrow down.

    Have you pass the value to the parameter?

    Here is a blog about passing-multi-value-parameter-in-stored-procedure-ssrs-report for your reference.

    Also recommend that you avoid using the sp_ prefix for naming stored procedures as this is a reserved prefix for system stored procedures.

    Regards,
    Zoe


    If the answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    What can I do if my transaction log is full?--- Hot issues November

    How to convert Profiler trace into a SQL Server table -- Hot issues November


  2. Dave Patrick 329.4K Reputation points Microsoft MVP
    2021-03-29T01:49:47.107+00:00

    I've seen that sort of behavior if the stored procs got edited after adding the datasets to report. I'd delete datasets from report, save, and then re-add them.

    No comments