How to aggregate with a joined subview in Sharepoint Designer
Hello.
I have a data view web part which uses a "Linked Sources" as Datasource. I have created a master table, then created the joined subview inside the data view web part as usual. Instead of showing the detail data in the subview, I just showed the
number of rows as this is what I am interested in.
The master table is grouped by a specific column, so here is a representation of what I have:
HEADER_A
FIELD_X FIELD_Z NUMBER(count of rows in the subview)
FIELD_Z FIELD_Z NUMBER
FOOTER_A (count of rows in the master table)
HEADER_B
FIELD_X etc...
FOOTER_B
the count of rows in the subview is given by the following:
count(../../../Publications/Rows/Row[@Journal=$dvt_ParentRow/@Title])
Now, in the footer I want to show the total count of rows of the subview , not the count of rows of the master table. How can I get the count of rows of the subview based on the grouping of the master table?
More specifically the problem is that the subview cannot be directly link to the group header; it can be joined to a field in the master table which must then be filtered based on the group header.
Thanks!
January 31st, 2011 6:30pm
Did you find an answer to this?
Free Windows Admin Tool Kit Click here and download it now
April 13th, 2011 10:57am
Add this below the </xsl:Call-template> of the joined subview:
<tr><td><xsl:value-of select="count(/dsQueryResponse/Votes/Rows/Row[@Post_x0020_ID=$dvt_ParentRow/@ID])" /></td></tr>
Votes is the name of the list
@Post_x0020_ID and @ID are the filter criteria that I want to count
Moderator Note: NEVER propose your own posts as answers. The "Propose as Answer" function is provided so that people can propose the good answers of
other people. It is NOT for self-proposing.
April 13th, 2011 10:59am
Add this below the </xsl:Call-template> of the joined subview:
<tr><td><xsl:value-of select="count(/dsQueryResponse/Votes/Rows/Row[@Post_x0020_ID=$dvt_ParentRow/@ID])" /></td></tr>
Votes is the name of the list
@Post_x0020_ID and @ID are the filter criteria that I want to count
Free Windows Admin Tool Kit Click here and download it now
April 13th, 2011 11:01am