If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

How to find previous maximum date

Started by shrini, 29 Aug 2014 11:19:01 AM

Previous topic - Next topic

shrini

For example:-

Policy No   Date
1   10/12/2013
1   1/8/2012
1   23/06/2013

For policy no1 result would be 23/06/2013. I dont have any transaction number for each date to pick. Please let me know, if anybody has solution.


Thanks,
Srini.

MDXpressor

#1
A couple of ways to manage this shrini.

but with some brute force:

[minDate]: 
minimum([Namespace].[Query Subject].[Date] for [Policy No])

Then, filter for:
[Namespace].[Query Subject].[Date]=[minDate]

This will leave you with only the 1st record. 


If you want all records to show up, allow a rank on dates per Policy No to become your ID's:
rank([Date] for [Policy No])

No, a proof is a proof. What kind of a proof? It's a proof. A proof is a proof, and when you have a good proof, it's because it's proven.

-Jean Chretien

shrini