Let's start with the basics. Here's the simplified structure of the data coming into the report:
ID | Tags
1 |A|
2 |A|B|
3 |B|
4 |A|C|D|
5 |B|D|
6 |D|A|C| --I added this row to show that tags could be in any order
I have a parameter on the report where users can choose one or more tags from a list (A,B,C,D)
Here's the output I'd like to see on the report. It'll be exported into Excel so I'll be using that to describe the desired output.
Sample report output: (Tag parameter selection: A and D)
Worksheet 1 = displays all records => [1,2,3,4,5,6]
Worksheet 2 = displays records that match all tags selected (must have tags for both A AND D!) => [4,6]
Worksheet 3 = displays records that have tag A => [1,2,4,6]
Worksheet 4 = displays records that have tag D => [4,5,6]
**Note: Worksheets 3 and up will show each of the tags selected in a separate worksheet, there could be 1 to N sheets.
Currently in the report I have 3 tables ready to go:
Table 1: Just displays the full query (nice and easy!) and has a PageName="All records"
Table 2: Need to filter full query down to match Worksheet 2 above and will have a PageName="Filtered records" This is problem #1! Looking for ideas on a filter query!
Table 3: Need to group the full query by Tag, but also only displays groups where the tag is in the list of tags selected in the parameter. This is problem #2! Can't just take the filter from Table 2 and then group because records would be missing (such as number 5 for tag D)
Any and all help would be greatly appreciated!!
Additional notes:
- Tag delimiter could be changed (I chose | because the data has commas)
- Regardless of delimiter, tags can only come back in one column (delimited list) due to aggregation in other columns