COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: dipstm on 16 May 2008 02:23:56 AM

Title: Regarding Dynamic Sorting in Cognos 8.3
Post by: dipstm on 16 May 2008 02:23:56 AM
Hi All,
I am using Cognos 8.3 in my project. I have a list report and want to sort the list report dynamically by clicking any one of headers of the list report. But the sorting should be performed on the whole query not only on the current list page displayed. I have got few support docs but those just dynamically sort the current list page.
   If anyone has something on this, plz let me know as I am trying this out from a long time.

Thanx in Advance

Regards,
Dipstm
Title: Re: Regarding Dynamic Sorting in Cognos 8.3
Post by: raro on 16 May 2008 04:04:08 AM
"Workaround":

- have different pages with same list but differently sorted per column
  e.g. if you have 5 columns in your list to be sorted, have 5 pages setting a different sort column on each page

- have a conditional layout variable selecting the page to be displayed
  e.g. variable=c1 .. will display a list sorted by column no.1 .. which is page1
  e.g. variable=c2 .. will display a list sorted by column no.2 .. which is page2
  and so on.

- on each page have a link setting the variable (e.g. constructing a URL-parameter)

let me know if this works for you.
Title: Re: Regarding Dynamic Sorting in Cognos 8.3
Post by: dipstm on 10 Jul 2008 04:27:56 AM
Hi raro,
I was trying ur workaround but its a more tedious task and in in addition to this, I want both ascending and descending sorting on column name of list report.
Is there any other way in Cognos 8.3 for dynamic sorting of list report which will sort the entire query and not only the current page of list report.
If anyone has tried dynamic Sorting plz share it as I am trying it out for quite a long time.

Thanx in advance,
Dipstm
Title: Re: Regarding Dynamic Sorting in Cognos 8.3
Post by: dipstm on 14 Jul 2008 12:55:35 AM
Hi All,
Is dynamic sorting possible in Cognos?
If yes, how it can be achieved?
If anyone has implemented dynamic sorting plz let me know.

Thanx in Advance...
Title: Re: Regarding Dynamic Sorting in Cognos 8.3
Post by: angela on 14 Jul 2008 10:28:51 AM
We don't have 8.3 yet, but there are techniques for this in 8.2 posted at http://it.toolbox.com/wiki/index.php/Category:Cognos8-l which might be of help.  I may have even seen some solutions in Cognoise - have you searched here for Dynamic Sorting?
Title: Re: Regarding Dynamic Sorting in Cognos 8.3
Post by: raro on 29 Jul 2008 05:56:02 AM
Querystudio allows dynamic sorting by default.

Did you try QS?
Title: Re: Regarding Dynamic Sorting in Cognos 8.3
Post by: raro on 29 Jul 2008 06:02:33 AM
Quote from: angela on 14 Jul 2008 10:28:51 AM
We don't have 8.3 yet, but there are techniques for this in 8.2 posted at http://it.toolbox.com/wiki/index.php/Category:Cognos8-l which might be of help.  I may have even seen some solutions in Cognoise - have you searched here for Dynamic Sorting?

The idea behind is clever:

"... <queryitem>CASE ?SortColumn? WHEN 1 THEN [Retailer name]WHEN 2 THEN [Retailer type]WHEN 3 THEN [City]WHEN 4 THEN 'Number'ELSE END</queryitem> ..." + some javascript to pass the variable on to a cognos-url when clicking on a column header.