Right click the parameter under the "Report Data" and select "Parameter Properties"
Select "Available Values" section
Click the "Get values from a query" option
4a. Select the appropriate query to use make sql for getting year data.
like this
with yearlist as
(
select 2004 as year
union all
select yl.year + 1 as year
from yearlist yl
where yl.year + 1 <= YEAR(GetDate())
)
select year from yearlist order by year desc;
Or Use stored procedure to get values.
4b. Select the Value that you want the main query to use to generate the data
4c. Select the Label that will show in the drop down box that the User sees and selects a option from
Member
504 Points
1776 Posts
Parameter
Dec 15, 2017 09:42 AM|JagjitSingh|LINK
Hi
In a parameter i want to display Years from 2002 to till current Year
Thanks
Member
150 Points
107 Posts
Re: Parameter
Dec 15, 2017 09:52 AM|Omkar Mhaiskar|LINK
Hi Jagjit
My solution:
Right click the parameter under the "Report Data" and select "Parameter Properties"
Select "Available Values" section
Click the "Get values from a query" option
4a. Select the appropriate query to use make sql for getting year data.
like this
Or Use stored procedure to get values.
4b. Select the Value that you want the main query to use to generate the data
4c. Select the Label that will show in the drop down box that the User sees and selects a option from
Omkar Mhaiskar
Software Engineer
Clarion Technologies