显示 Reporting Services 矩阵中重叠范围的聚合
我在显示矩阵行中一系列日期的值时遇到问题。我希望有一个矩阵显示以下数据:
Trial Existing Total Yesterday 3 1 4 This Week 5 3 8 Last Week 18 5 23 Month to Date 26 9 35 Last Month 32 20 52
我认为解决方案是创建一个计算字段,其中包含取消范围的文本值(“昨天”、“本周”等)。问题在于这些日期范围重叠,并且该字段只能保存一个文本值。
有没有办法在 Reporting Services 中创建这样的矩阵表?
I'm having a problem displaying the values for a range of dates in a matrix row. I would like to have a matrix display the following data:
Trial Existing Total Yesterday 3 1 4 This Week 5 3 8 Last Week 18 5 23 Month to Date 26 9 35 Last Month 32 20 52
I thought the solution would be to create a calculated field with the text values for the cancel range ('Yesterday', 'This Week', etc.). The problem is that those date ranges overlap and the field can only hold one text value.
Is there a way to create a matrix table like this in Reporting Services?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果我可以建议,为什么不在查询中使用 UNION 创建具有相同数据的 SQL 结果集?
例如
注意:我编写此查询是为了向您提供如何在 SQL 中完成此查询的示例。以免依赖 Reporting Services 来完成该工作。
并且您将不得不做一些杂耍才能使用 tsql 中的 DATE 相关函数来获取“本周”的日期。
总计字段可以是报告中的计算字段。
If I may suggest, why not create a SQL resultset with same data using UNION in the query?
e.g.
Note: I have written this query to give you an example of how it can be done in SQL. So as to not rely on Reporting Services to do the work.
And you will have to do some juggling to get the dates of "This week" using DATE related functions in tsql.
The Total field can be a calculated field in the report.