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.
I have a list of items, that are both alpha and numeric. By default the alpha items appear last in the list. How can I have them appear before the numeric items.This message has been edited. Last edited by: kitten,
WebFOCUS 7.6.2, MS Windows Server/______, Excel, PDF, HTML
You can set a variable (&AlfNum = IF ... THEN ... ELSE ...) or field (AlfNum/A1 = IF ... THEN ... ELSE ...) to check for alpha / numberic and sort (NOPRINT) on that first.
What's your source (TABLE or DM)? Can you provide a sample?
Posts: 3132 | Location: Tennessee, Nashville area | Registered: February 23, 2005
So you want your reports' sort sequence to resemble EBCDIC collation sequence.
It should be sufficient to group the values according to the first character, and allow ASCII order to take it from there. Just DEFINE:
myInit/A1 = EDIT(myField,'9');
mySort/A1= IF myInit GE '0' AND myInit LE '9' THEN 'A'
ELSE IF myInit GE 'A' AND myInit LE 'Z' THEN '0'
ELSE IF myInit GE 'a' AND myInit LE 'z' THEN '0'
ELSE myInit;
and sort your report
BY mySort NOPRINT
BY myField
- Jack Gross WF through 8.1.05
Posts: 1925 | Location: NYC | In FOCUS since 1983 | Registered: January 11, 2005
I would use Doug's idea. In this example, I isolate the first character of MODEL and determine if it's alpha or numeric:
DEFINE FILE CAR
MODEL1/A1 = SUBSTR(20, MODEL, 1, 1, 1, 'A1');
ALPHA_NUM/A1 = IF CHKFMT(1, MODEL1, '9', 'I6') EQ 0 THEN 'N' ELSE 'A';
END
TABLE FILE CAR
SUM
SALES
BY ALPHA_NUM NOPRINT
BY MODEL
END
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