Focal Point Banner
Community Center Education Summit Technical Support User Groups
Let's Get Social!

Facebook Twitter LinkedIn YouTube
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Order of bars in a graph
Go
New
Search
Notify
Tools
Reply
  
Order of bars in a graph
 Login/Join
 
Platinum Member
posted
I need the order of the bars to be from lowest retail_cost to highest retail_cost and not sorted by country name. The graph is needed in the same format just a diffenent sort order.

GRAPH FILE CAR
SUM RETAIL_COST
ACROSS COUNTRY
END


WF 8 version 8.2.04. Windows.
In focus since 1990.
 
Posts: 189 | Location: pgh pa | Registered: October 06, 2004Reply With QuoteReport This Post
Expert
posted Hide Post
quote:
GRAPH FILE CAR
SUM RETAIL_COST
ACROSS COUNTRY
COLUMNS 'ENGLAND' AND 'FRANCE' AND 'ITALY' AND 'BURKINA FASO'
END




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
 
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003Reply With QuoteReport This Post
Platinum Member
posted Hide Post
susannah,

that works for the car file but i will not know what columns will be showing on my real report. the real report is the top 10 customers base on sales $.


WF 8 version 8.2.04. Windows.
In focus since 1990.
 
Posts: 189 | Location: pgh pa | Registered: October 06, 2004Reply With QuoteReport This Post
Expert
posted Hide Post
then you gotta do a little work to earn your paycheck.
figure out the top 10 in a fex paragraph BEFORE the GRAPH FILE paragraph, and write your COLUMNS line dynamically.
TABLE FILE CAR
BY HIGHEST TOTAL SALES NOPRINT BY COUNTRY ON TABLE SAVE AS MYCOUNTRY
END
-RUN
-SET &HOWMANY = &LINES;
-SET &KOUNTER = 0 ;
GRAPH FILE CAR
SUM RETAIL_COST ACROSS COUNTRY
COLUMNS
-REPEAT end.loop &HOWMANY TIMES
-SET &KOUNTER = &KOUNTER +1 ;
-READ MYCOUNTRY NOCLOSE &COUNTRY.A10
-SET &THING = IF &KOUNTER NE &HOWMANY THEN '''' | &COUNTRY || '''' | ' AND '
- ELSE '''' | &COUNTRY | '''' ;
&THING.EVAL
-end.loop
END
-* make SURE you put a space after the word COLUMNS
I think, if i recall correctly, that NOPRINT won't work in GRAPH FILE
so ACROSS someSalesRank NOPRINT ACROSS COUNTRY
won't work although it would seem the obvious thing for TABLE FILE. so that's why you have to jump thru this hoop. but its easy enough. I think T taught me this, or Francis, some years ago when i had the same issue.

Merry Christmas...i'm so outa here!

This message has been edited. Last edited by: susannah,




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
 
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003Reply With QuoteReport This Post
Platinum Member
posted Hide Post
thank you susannah.


WF 8 version 8.2.04. Windows.
In focus since 1990.
 
Posts: 189 | Location: pgh pa | Registered: October 06, 2004Reply With QuoteReport This Post
Platinum Member
posted Hide Post
I thank the Susannah from this date:
quote:
December 20, 2006 06:44 PM
It just helped me on 9/20/2013... LOL In regards to how to sort by the columns. Your example worked like a charm with my graph!


Currenly working @ Learning Circle Education Services
Previously worked @ Nationwide Insurance
Prod: WebFOCUS 7.6.11


Test: WebFOCUS 7.6.11


Dev: WebFOCUS 7.6.11
 
Posts: 125 | Location: Columbus, Ohio | Registered: March 31, 2006Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Order of bars in a graph

Copyright © 1996-2018 Information Builders, leaders in enterprise business intelligence.