Need to print values from multiple rows in the dataset to a single row in the details based on main group, questiontab, row, and column IDs.
Looking for advice on if this is possible in SSRS, possibly using nested tables or lookup/lookupset/join?
Unable to add any functions or procs at the DB level, limited to the existing dataset format.
Column # is limited to 1 or 2 only
Dataset
| MainGroup | QuestionTab | QuestionRow | QuestionColumn | Question | Answer |
|-----------|-------------|-------------|----------------|-------------|-----------|
| Group1 | TabA | 1 | 1 | Question1 | Answer1 |
| Group1 | TabA | 1 | 2 | Question2 | Answer2 |
| Group1 | TabA | 2 | 1 | Question3 | Answer3 |
| Group1 | TabA | 2 | 2 | Question4 | Answer4 |
| Group1 | TabB | 1 | 1 | Question234 | Answer234 |
| Group1 | TabB | 2 | 1 | Question789 | Answer789 |
Current Output, tried various groupings and expressions with lookup, lookupset, join
| MainGroup | QuestionTab | QuestionRow | Question1output | Answer1output | Question2output | Question2output |
|-----------|-------------|-------------|-----------------|---------------|-----------------|-----------------|
| Group1 | TabA | 1 | Question1 | Answer1 | | |
| Group1 | TabA | 1 | | | Question2 | Answer2 |
| Group1 | TabA | 2 | Question3 | Answer3 | | |
| Group1 | TabA | 2 | | | Question4 | Answer4 |
etc etc
Desired Output
| MainGroup | QuestionTab | QuestionRow | Question1output | Answer1output | Question2output | Question2output |
|-----------|-------------|-------------|-----------------|---------------|-----------------|-----------------|
| Group1 | TabA | 1 | Question1 | Answer1 | Question2 | Answer2 |
| Group1 | TabA | 2 | Question3 | Answer3 | Question4 | Answer4 |
| Group1 | TabB | 1 | Question234 | Answer234 | | |
| Group1 | TabB | 2 | Question789 | Answer789 | | |