简体   繁体   English

如何在SSRS 2005中创建月份年份下拉参数?

[英]How to create month year drop down parameter in SSRS 2005?

In SSRS 2005, I need to provide a drop down to the user with month year labels for the last two months. 在SSRS 2005中,我需要为用户提供最近两个月的年份标签。 For eg Jan 2010, Feb 2010, ... , Jan 2011, .... Dec 2011 例如,2010年1月,2010年2月,...,2011年1月,.... 2011年12月

I need this dynamically for the last two years (say). 在过去的两年中,我动态地需要它(例如)。

Additionally, as user select one of the label, I need to pass the last date of the selected month-year combination to the query parameter. 另外,当用户选择其中一个标签时,我需要将所选月份-年份组合的最后日期传递给查询参数。

Please help! 请帮忙!

Sijoy 西约

Assuming you are reporting from a SQL datasource, create a new dataset with a query to return the last date of each month within the required range (ie. the last two months) and the month-year description of each month - the details of the query will vary depending on the SQL database (MySQL, SQLServer, Oracle, etc). 假设您要从SQL数据源进行报告,请创建一个新的数据集,并使用查询返回所需范围内每个月的最后日期(例如最近两个月)以及每个月的月年说明-详细信息查询会因SQL数据库(MySQL,SQLServer,Oracle等)而异。 Populate the parameter from this new dataset, and set the value to be the date field and the label to be the description field. 从此新数据集中填充参数,并将值设置为日期字段,将标签设置为描述字段。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM