Monday, March 26, 2012

How to use the same stored procedure to display two different char

I need to display two charts on a report based on the same stored procedure
that accepts a single parameter. I do not wish to be promted for the
parameter. Instead, I would like to pass two different values to each chart
within the report.
Please advise.
Thanks,
KonstantinHow do you know what value to pass it?
Anyway, something to get you going in the right direction. First thing to
realize is that query parameters and report parameters are two different
things. RS automatically creates a report parameter for you for each stored
procedure query parameter it sees. But, you don't have to use it. You can
map it to an expression instead. Click on the ..., parameters tab. On the
right pick change it from mapping to a report parameter and map it to an
expression instead.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Konstantin Shaumyan" <KonstantinShaumyan@.discussions.microsoft.com> wrote
in message news:3A7E2C6B-FF43-4993-9B21-04EA79316410@.microsoft.com...
>I need to display two charts on a report based on the same stored procedure
> that accepts a single parameter. I do not wish to be promted for the
> parameter. Instead, I would like to pass two different values to each
> chart
> within the report.
> Please advise.
> Thanks,
> Konstantin|||Thanks for the tip.
I created two datasets based on the same stored procedure for each graph and
set my parameter for each dataset to literals.
Everything worked as expected.
Regards,
Konstantin
"Bruce L-C [MVP]" wrote:
> How do you know what value to pass it?
> Anyway, something to get you going in the right direction. First thing to
> realize is that query parameters and report parameters are two different
> things. RS automatically creates a report parameter for you for each stored
> procedure query parameter it sees. But, you don't have to use it. You can
> map it to an expression instead. Click on the ..., parameters tab. On the
> right pick change it from mapping to a report parameter and map it to an
> expression instead.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Konstantin Shaumyan" <KonstantinShaumyan@.discussions.microsoft.com> wrote
> in message news:3A7E2C6B-FF43-4993-9B21-04EA79316410@.microsoft.com...
> >I need to display two charts on a report based on the same stored procedure
> > that accepts a single parameter. I do not wish to be promted for the
> > parameter. Instead, I would like to pass two different values to each
> > chart
> > within the report.
> >
> > Please advise.
> >
> > Thanks,
> > Konstantin
>
>sql

No comments:

Post a Comment