Traditional web-based reporting with SAS BI tools

How to get a sorted table by columns in a crosstabulation table in WRS

Reply
Occasional Contributor
Posts: 14

How to get a sorted table by columns in a crosstabulation table in WRS

hi
Right now my WRS report is sorted by observations(rows) in alphabetical order when the report is opened. Is that possible to get a sorted crosstabulation table by a certain column right away when you click "View Report" ?

thanks in advance

-psysas

Message was edited by: psysas Message was edited by: psysas
SAS Employee
Posts: 105

Re: How to get a sorted table by columns in a crosstabulation table in WRS

Hi, you can use proc format that places the selected column values in a specified numeric order.

You can find an example in the following sas note:

http://support.sas.com/kb/33/017.html

I hope this helps you...
Occasional Contributor
Posts: 14

Re: How to get a sorted table by columns in a crosstabulation table in WRS

hi yonib
thanks for your reply.
but the column value is already numeric, i need it sorted when the report is opened.
any ideas?

-psysas
Occasional Contributor
Posts: 14

How to get a sorted table by columns in a crosstabulation table in WRS

anyone has an idea? is that due to the data source which is an olap cube?

SAS Employee
Posts: 37

How to get a sorted table by columns in a crosstabulation table in WRS

If the source is an OLAP cube, the default view should be sorted based on the sort you defined for that dimension in your cube.  You ahve the ability to define the sort order using five options:

1.  Formatted Ascending

2.  Formatted Descending

3.  Unformatted Ascending

4.  Unformatted Descending

5.  Data set order

I would suggest setting the sort order for this dimension according to how you would like your default view in WRS to appear.

Occasional Contributor
Posts: 14

How to get a sorted table by columns in a crosstabulation table in WRS

hi TSBruce

Thanks for your reply.

it is my fault that I havn´t make it clear. It is the measures that need to be sorted in either ascending or descending order.

really hope someone can help.

-psysas

SAS Super FREQ
Posts: 620

How to get a sorted table by columns in a crosstabulation table in WRS

In the View Mode, you go to the column in questions, use the right mouse button select either sort asceding or sort descending. Then save the report. That should do it.

Occasional Contributor
Posts: 14

How to get a sorted table by columns in a crosstabulation table in WRS

well Bruno, the users require that the column is displayed sorted when they click "View report" in WRS. Is that possible?

SAS Super FREQ
Posts: 620

How to get a sorted table by columns in a crosstabulation table in WRS

When you save the report it remembers the sorting. So when you view a report it will use the sorting you specified

Occasional Contributor
Posts: 14

How to get a sorted table by columns in a crosstabulation table in WRS

ya... but if you have a prompted filter, it will only save the sorting to the report you specified in your filter. An example: your prompted filter has two groups A and B. If you choose group A in your prompt and save the sorting. The report is viewed sorted for group A. But if you opdate your report by selecting group B in your prompt, the report for group B is not sorted.

any idea?

SAS Super FREQ
Posts: 620

How to get a sorted table by columns in a crosstabulation table in WRS

pysas I think you best discuss this with technical support and outline the steps you used to produce the the prompt as well as the report

Occasional Contributor
Posts: 14

How to get a sorted table by columns in a crosstabulation table in WRS

thanks Bruno, i will do that

SAS Employee
Posts: 37

How to get a sorted table by columns in a crosstabulation table in WRS

I just tested this with WRS4.3 and the sort is remembered and honored even when selecting different values for prompts or anytime the report is opened.  It is a requirement to save the report with the sort applied, as this saves the sort in the report definition.

Post a Question
Discussion Stats
  • 12 replies
  • 403 views
  • 0 likes
  • 4 in conversation