C
C#2y ago
FR

❔ SQL SERVER | SSRS | Dataset Column not Refresh When Using Stored Procedure with Parameter

so i have a Report with multiple dataset and i want to make it easy for maintenance so i created sp that store multiple select data and access it with parameter but when i implement it to SSRS the default column always use the first query even the param is different i try to spam the refresh button but didnt work.... any solution/alternative or did i do something wrong ? ty.. sample SP and Picture :
ALTER Procedure [dbo].[sp_reportMonthly]
@inputReportPart varchar(20)
as
begin
IF(@inputReportPart = '1' or @inputReportPart = 'debug')
BEGIN
select a,b,c from table1
END
IF(@inputReportPart = '2' or @inputReportPart = 'debug')
BEGIN
select q,w,e from table2
END
end
ALTER Procedure [dbo].[sp_reportMonthly]
@inputReportPart varchar(20)
as
begin
IF(@inputReportPart = '1' or @inputReportPart = 'debug')
BEGIN
select a,b,c from table1
END
IF(@inputReportPart = '2' or @inputReportPart = 'debug')
BEGIN
select q,w,e from table2
END
end
1 Reply
Accord
Accord2y ago
Looks like nothing has happened here. I will mark this as stale and this post will be archived until there is new activity. Was this issue resolved? If so, run /close - otherwise I will mark this as stale and this post will be archived until there is new activity.
Want results from more Discord servers?
Add your server