问题
I’m using COGNOS 11 and I’m trying to create a report that only returns the duplicate data in a row only.
I’ve tried everything in the IBM user guide but not happening for me.
Probably a simple solution but it’s been a long day, any help would be appreciated, thank you in advance.
回答1:
determine how you want to group the data (this will identify the duplicates) For example, if you wanted to find duplicate items in the same order (maybe on different order lines)
based on your data grouping, create a data item (like Count Dupe) to count the rows of data
For example the expression would look like this:
count([Line] for [Company Code],[Order],[Item Code])
A good trick for this is to build a list. Then group the data by how it duplicates (i.e. company, order, items). The last level that would reveal the duplicate, becomes the thing you want to count. In the example, it's the line number because we will see the same item for the same order on different lines
- For the filter, set the property AFTER AGGREGATION filter like this:
[Count Dupe] > 1
来源:https://stackoverflow.com/questions/64776350/cognos-report-for-duplicate-data-only