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 get the last value of the column in list report

Started by podaralla, 15 Oct 2014 07:27:52 AM

Previous topic - Next topic

podaralla

Dear Experts,

How to get the last value of the column in cognos list report.

could any one help me out this.

Best Regards

BigChris

What makes it the last value in the list? Is the list sorted in anyway? If, for example, it's sorted on date you could create a second query to find the maximum date then link that query to the first one to find the last value.

podaralla

Hi ,

thanks for reply, yes its based on date, can you explain me how we can do? i am new to cognos.

Best Regards

BigChris

Ok, this is fairly broad brush strokes, but I'll give it a go. Let's say the query you've got at the moment has got two fields in it:

[YourTable].[Date] and [YourTable].[Attribute]

You could create a second query that just has one field in it - a calculation of maximum([YourTable].[Date])...give it a name like MaxDate

In your query design you can now drag in a join, which will create a third query, and will have two placeholders. Drag your first query into the first placeholder and you second into the other. Double click on the join and link Query1.Date to Query2.MaxDate

In the new third query drag in Date and Attribute from Query1 - you should now just see the records for the latest date.

It's hard to describe, but hopefully if you have a play around you should be able to see what I'm trying to describe.