Solved

IBM COGNOS Report Query Question:  Limiting a list to only the latest entry for a given MsrCd

Posted on 2014-02-04
2
410 Views
Last Modified: 2014-02-05
In a Performance Measure History table is a list of when the users periodically key in their  info regarding their targets.
However, for most of the requested reports all that is wanted is the latest entry for a given Measure.  Measures are uniquely identified with a MsrCd#.
The History table not only has a unique date/time of entry, but each entry in the table creates a unique sequential ID.
None of the reports want to see either the entry date, MsrCd or the ID, and I have unsuccessfully been attempting to -behind the scenes- create such a filter, via “Data item”,  “Filter”, Query Calculation, etc. using the below syntax.  On occasion the syntax gets approved, but I do not accomplish my goal.

maximum ( [PM View prd].[DataTarget History].[ID]  for  [PM View prd].[DataTarget History].[MsrCd]  )

Assistance please.
0
Comment
Question by:willjx
2 Comments
 
LVL 12

Accepted Solution

by:
RWrigley earned 500 total points
ID: 39835267
Probably the easiest way I can think of is to create a dataitem like:
rank([PM View prd].[DataTarget History].[ID]  for [PM View prd].[DataTarget History].[MsrCd]  )

Then add a detail filter for [rankMSR] = 1
0
 

Author Closing Comment

by:willjx
ID: 39836536
Thank you very much.
You just saved me innnumerable hours of trial and error attempts. I was totally on a different track.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

In database programming, custom sort order seems to be necessary quite often, at least in my experience and time here at EE. Within the realm of custom sorting is the sorting of numbers and text independently (i.e., treating the numbers as number…
Composite queries are used to retrieve the results from joining multiple queries after applying any filters. UNION, INTERSECT, MINUS, and UNION ALL are some of the operators used to get certain desired results.​
This video discusses moving either the default database or any database to a new volume.
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now