反转矩阵控件中嵌套列组的标题行
在矩阵控件中,我按“大小”对列进行分组,然后按“颜色”对列进行分组。生成的表格如下所示:
我需要反转标题行,因此表格如下所示:
子组中的值应显示在父组中相应值的上方。
In a matrix control, I group columns by 'Size', and then by 'Color'. The resulting table looks like this:
I need to invert the header rows, so the table looks like this:
The values from the child group should display above the corresponding value from the parent group.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
也许可以通过将“父组”设置为“大小”和“颜色”的组合分组,但仅显示颜色,然后按子组/子组的“大小”进行分组。
更新:
好的,所以我创建了一个小数据集,我不确定该数据集是否与您返回的数据集相同,但也许它可以激发一些关于如何在 SQL 中操作数据以帮助获得您想要的内容的其他想法报告。
首先,我刚刚创建了一堆 SELECT ... UNION ALL 语句,但经过一番尝试后,我仍然无法获得接近所需视觉输出/分组的任何内容。所以这就是我使用的:
你可以忽略
CSGroup
我最终没有使用它。因此,它给了我你的“外观”需要在数据集中。
我制定了一个矩阵并按大小和分组进行分组。 Color (
=Fields!size.Value & Fields!color.Value
)I 然后插入一个组,并按 Size (
=Fields!size.Value
) 进行分组“顶部”列分组我有
=Fields!color.Value
在第二列分组中我有
=First(Fields!Size.Value)
在数据文本框中我有 < code>=Sum(Fields!Amount.Value)
然后,右键单击第二个列分组并选中“隐藏重复项”框。然后我在下拉列表中选择了
Dataset1
。我唯一无法做的就是使大小居中,因为我无法合并文本框。
Maybe by making the Parent group a combined grouping of both Size and Color, however only display Colors, then Group on Size for the Child/Subgroup.
Update:
Ok, so I created a small dataset, I'm not sure the dataset is anything like you are getting back, but maybe it can spur some other ideas on how you can manipulate the data in SQL to help get what you want in the report.
First I just created a bunch of SELECT ... UNION ALL statements, but after some toying, I still couldn't get anything close to the required visual output/grouping. So here is what I used:
You can ignore the
CSGroup
I didn't end up using it.So with that, it about gave me the "look" of what you need in the Dataset.
I drug out a Matrix and grouped on Size & Color (
=Fields!size.Value & Fields!color.Value
)I Then inserted a group, and grouped on Size (
=Fields!size.Value
)In the "top" column grouping I have
=Fields!color.Value
In the second column grouping I have
=First(Fields!Size.Value)
In the Data textbox I have
=Sum(Fields!Amount.Value)
Then, Right-Click on the second Column Grouping and Check the Box "Hide Duplicates". I then selected
Dataset1
in the drop down.The only thing I was Unable to do was get the Size centered since I was unable to Merge the textboxes.