Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     <Solve>Rank with Sort Groups

Read-Only Read-Only Topic
Go
Search
Notify
Tools
<Solve>Rank with Sort Groups
 Login/Join
 
Silver Member
posted
Hello;

I searched through the positings and was not able to find an answer to this. I have two sort groups both of have YTD sales. One just has the YTD sales and then the other one has it segmented out across. I am able to sort the report by YTD sales, but I am unable to add a rank to it. When I add a rank it comes back with this error

(FOC020) THE SETS OF SORT PHRASES ARE INCONSISTENT
(FOC009) INCOMPLETE REQUEST STATEMENT
BYPASSING TO END OF COMMAND


Has anyone seen this?

Thanks

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


WebFocus 7.6.4
SQL
HTML and Excel
 
Posts: 49 | Registered: June 06, 2008Report This Post
Expert
posted Hide Post
How about posting an example using the CAR file?


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
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Silver Member
posted Hide Post
TABLE FILE CAR
SUM
     SALES
 RANKED  AS 'RANK' BY TOTAL HIGHEST SALES NOPRINT
BY COUNTRY
SUM
     SALES AS ''
 RANKED  AS 'RANK' BY TOTAL HIGHEST SALES NOPRINT
BY COUNTRY
ACROSS CAR
HEADING
""
FOOTING
""
ON TABLE SET PAGE-NUM OFF
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT EXL2K
ON TABLE SET STYLE *
     UNITS=IN,
     SQUEEZE=ON,
     ORIENTATION=PORTRAIT,
$
TYPE=REPORT,
     GRID=OFF,
     FONT='ARIAL',
     SIZE=9,
$
TYPE=TITLE,
     STYLE=BOLD,
$
TYPE=TABHEADING,
     SIZE=12,
     STYLE=BOLD,
$
TYPE=TABFOOTING,
     SIZE=12,
     STYLE=BOLD,
$
TYPE=HEADING,
     SIZE=12,
     STYLE=BOLD,
$
TYPE=FOOTING,
     SIZE=12,
     STYLE=BOLD,
$
TYPE=SUBHEAD,
     SIZE=10,
     STYLE=BOLD,
$
TYPE=SUBFOOT,
     SIZE=10,
     STYLE=BOLD,
$
TYPE=SUBTOTAL,
     BACKCOLOR=RGB(210 210 210),
$
TYPE=ACROSSVALUE,
     SIZE=9,
$
TYPE=ACROSSTITLE,
     STYLE=BOLD,
$
TYPE=GRANDTOTAL,
     BACKCOLOR=RGB(210 210 210),
     STYLE=BOLD,
$
ENDSTYLE
END
  


WebFocus 7.6.4
SQL
HTML and Excel
 
Posts: 49 | Registered: June 06, 2008Report This Post
Virtuoso
posted Hide Post
I don't believe you can use RANK with a multi-verb set. That's probably the quickest answer. However, you can take out the RANKED AS 'RANK' on both lines and the report appears in the correct sort order.

Now why the Report Painter would let you create this procedure as you have done when it doesn't work is an entirely different question.


Regards,

Darin



In FOCUS since 1991
WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex
Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex
WF Client: 77 on Linux w/Tomcat
 
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007Report This Post
Silver Member
posted Hide Post
So if you cannot do it, then is their anway for a number Rank to dispaly on the left side?


Thanks so much for your information....


WebFocus 7.6.4
SQL
HTML and Excel
 
Posts: 49 | Registered: June 06, 2008Report This Post
Master
posted Hide Post
This isn't the most efficient way, but it will give you what you want. If your number of ACROSS columns vary, you will need to calculate how many you have.
SET ASNAMES=ON
SET HOLDLIST=PRINTONLY
TABLE FILE CAR
SUM
     SALES AS 'TOTAL_SALES'
  BY TOTAL HIGHEST SALES NOPRINT
BY COUNTRY
SUM
 
     SALES AS ''
  BY TOTAL HIGHEST SALES NOPRINT
BY COUNTRY
ACROSS CAR
ON TABLE HOLD AS HOLD1
END
TABLE FILE HOLD1
PRINT 
COMPUTE RANK/I5= LAST RANK +1; 
E01 E02 E03 E04 E05 E06 E07 E08 E09 E10 E11 E12
BY HIGHEST TOTAL_SALES NOPRINT
BY COUNTRY NOPRINT 
HEADING
""
FOOTING
""
ON TABLE SET PAGE-NUM OFF
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT EXL2K
ON TABLE SET STYLE *
     UNITS=IN,
     SQUEEZE=ON,
     ORIENTATION=PORTRAIT,
$
TYPE=REPORT,
     GRID=OFF,
     FONT='ARIAL',
     SIZE=9,
$
TYPE=TITLE,
     STYLE=BOLD,
$
TYPE=TABHEADING,
     SIZE=12,
     STYLE=BOLD,
$
TYPE=TABFOOTING,
     SIZE=12,
     STYLE=BOLD,
$
TYPE=HEADING,
     SIZE=12,
     STYLE=BOLD,
$
TYPE=FOOTING,
     SIZE=12,
     STYLE=BOLD,
$
TYPE=SUBHEAD,
     SIZE=10,
     STYLE=BOLD,
$
TYPE=SUBFOOT,
     SIZE=10,
     STYLE=BOLD,
$
TYPE=SUBTOTAL,
     BACKCOLOR=RGB(210 210 210),
$
TYPE=ACROSSVALUE,
     SIZE=9,
$
TYPE=ACROSSTITLE,
     STYLE=BOLD,
$
TYPE=GRANDTOTAL,
     BACKCOLOR=RGB(210 210 210),
     STYLE=BOLD,
$
ENDSTYLE
END
  


Pat
WF 7.6.8, AIX, AS400, NT
AS400 FOCUS, AIX FOCUS,
Oracle, DB2, JDE, Lotus Notes
 
Posts: 755 | Location: TX | Registered: September 25, 2007Report This Post
Silver Member
posted Hide Post
This was helpful....


WebFocus 7.6.4
SQL
HTML and Excel
 
Posts: 49 | Registered: June 06, 2008Report This Post
Gold member
posted Hide Post
This is an old thread, but I've run into this situation (i.e., RANK and FOC020) before. This works:
TABLE FILE CAR
SUM
    SALES
RANKED BY TOTAL HIGHEST SALES NOPRINT
BY COUNTRY
SUM
    SALES AS ''
BY RANK
BY SALES
BY COUNTRY
ACROSS CAR AS ''
END

Craig


v8.1.04, 64-bit Windows (Reporting Server), Apache Tomcat (Web/App Server), HTML, PDF, AHTML, Excel outputs
 
Posts: 57 | Location: Des Moines, IA | Registered: April 30, 2009Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     <Solve>Rank with Sort Groups

Copyright © 1996-2020 Information Builders