Focal Point
sort on sum field

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/8171037271

June 19, 2006, 07:04 PM
wf1998
sort on sum field
is there any way we can sort the SUM field in Graph,
here is my GRAPH Request, it's producing Attaiment Bars for each DIVISION.
bars are sorting on DIVISION, But i want to sort on ATT01.
Thanks in advance.

GRAPH FILE HOLDS
HEADING
"SUM ATT01 AS ''
ACROSS DIVISION AS ' '
BY CUSTOMER
ON GRAPH SET LOOKGRAPH HBAR
ON GRAPH SET GRAPHEDIT SERVER
ON GRAPH SET BARNUMB ON
ON GRAPH SET 3D OFF
ON GRAPH SET VZERO ON
ON GRAPH SET GRID ON
ON GRAPH SET VAXIS 400
ON GRAPH SET HAXIS 800
ON GRAPH SET GRWIDTH 0
ON GRAPH SET GRAPHSTYLE *

-* Graph style

ENDSTYLE
END




Env Prod:WebFOCUS 7702 ,Windows xp on 64, SQL Server 2008, IRF Tool
Env 1 Local: DevStudio 7702 - MS Windows XP SP2 - Apache Tomcat 5.0.28
Output: HTML, Excel and PDF
June 19, 2006, 10:00 PM
Francis Mariani
Here's what we've done:

TABLE FILE HSALR2
SUM
COMPUTE CTR/I1 = CTR + 1; NOPRINT
COMPUTE RGNX/A57 =
IF CTR EQ 1 THEN '''' || RGN || '''' ELSE ' AND ' | ('''' || RGN || '''');

BY HIGHEST AMOUNT NOPRINT

ON TABLE SAVE AS HSORTORD
END
-RUN

GRAPH FILE HSALR2
SUM
AMOUNT AS ''
ACROSS RGN AS ''

COLUMNS
-INCLUDE HSORTORD

ON TABLE HOLD AS GEIDS1 FORMAT HTMTABLE
...

I'll explain if it's required.

Cheers.


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
June 23, 2006, 01:06 PM
wf1998
Hi francis,

it will work for one Graph, but it's not working multiple graphs in a single graph request, is there any dynamic way to do it.
-Raj




Env Prod:WebFOCUS 7702 ,Windows xp on 64, SQL Server 2008, IRF Tool
Env 1 Local: DevStudio 7702 - MS Windows XP SP2 - Apache Tomcat 5.0.28
Output: HTML, Excel and PDF
June 29, 2006, 11:37 AM
Kerry
Hi Raj,

Has this issue been resolved on your side?

I am wondering, when you say "it will work for one Graph, but it's not working multiple graphs in a single graph request", will it work if you run one request for each graph? Will the output be the same as expected?

Here is some info from our product management, which may be of interest:
Customize Graph dynamically
https://forums.informationbuilders.com/eve/forums/a/tpc/...421084941#2421084941

Hope it helps. Smiler

Cheers,

Kerry


Kerry Zhan
Focal Point Moderator
Information Builders, Inc.
June 29, 2006, 06:22 PM
susannah
use COLUMNS command to reference the columuns in the order you want them.




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID