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.
After much searching, I am stumped. I am trying to run a fex and then take the ouput from that fex to set an amper variable to be used elsewhere in a larger procedure. This would be like a subroutine. My code is as follows:
-TOP
-SET &ECHO=ALL;
-? &
TABLE FILE RORCRHR
SUM
'RORCRHR.RORCRHR.RORCRHR_AIDY_CODE' AS 'AIDY'
BY 'RORCRHR.RORCRHR.RORCRHR_TERM_CODE' AS 'Term' NOPRINT
WHERE RORCRHR.RORCRHR.RORCRHR_TERM_CODE EQ '&TERM';
ON TABLE SET HOLDFORMAT ALPHA
-*ON TABLE PCHOLD FORMAT HTML
ON TABLE HOLD AS HOLDAIDY
END
-RUN
-READ HOLDAIDY &AIDY.A4. CLOSE
-IF &IORETURN NE 0 GOTO ENDIT;
-TYPE &AIDY
-ENDIT;
If I run just the fex out to HTML, I get a valid value. Useing -TYPE, is gives me zeros. Is this possible? What am I doing wrong?This message has been edited. Last edited by: paulI,
Prod: WF 7.7.05, BID, MRE, 7.7.06M Server, Windows 2008, RedHat, Oracle 11gR1, MS Office 2010 Test: I wish we had one!
SET HOLDLIST = PRINTONLY
-SET &IORETURN = 0;
TABLE FILE RORCRHR
SUM
'RORCRHR.RORCRHR.RORCRHR_AIDY_CODE' AS 'AIDY'
BY 'RORCRHR.RORCRHR.RORCRHR_TERM_CODE' AS 'Term' NOPRINT
WHERE RORCRHR.RORCRHR.RORCRHR_TERM_CODE EQ '&TERM';
ON TABLE HOLD AS HOLDAIDY FORMAT ALPHA
END
-RUN
-REPEAT ENDIT WHILE (&IORETURN EQ 0)
-READ HOLDAIDY NOCLOSE &AIDY.A4.
-TYPE &AIDY
-ENDIT
-CLOSE HOLDAIDY
SET HOLDLIST = PRINTONLY
TABLE FILE RORCRHR
SUM
COMPUTE CNTR/I9 = LAST CNTR + 1 ; NOPRINT
COMPUTE CODE/A?? = '-SET &AIDY' || LJUST(FTOA(CNTR,'(F9)','A9'),'A9') || '=''' || 'RORCRHR.RORCRHR.RORCRHR_AIDY_CODE' || ''';' ;
BY 'RORCRHR.RORCRHR.RORCRHR_TERM_CODE' AS 'Term' NOPRINT
WHERE RORCRHR.RORCRHR.RORCRHR_TERM_CODE EQ '&TERM';
ON TABLE HOLD AS HOLDAIDY FORMAT ALPHA
END
-RUN
-SET &AIDYCNT = &LINES ;
-INCLUDE HOLDAIDY
-? &AIDY
-REPEAT AIDYLOOP FOR &CNTR FROM 1 TO &AIDYCNT
-TYPE &AIDY.&CNTR
-AIDYLOOP
Thank you Mary and Waz. I used tidbits from both and a little more digging and came up with the following:
-TOP
-*SET &ECHO=ALL;
-*? &
DEFINE FILE RORCRHR
AIDY1/A4V=RORCRHR.RORCRHR.RORCRHR_AIDY_CODE;
END
TABLE FILE RORCRHR
BY 'RORCRHR.RORCRHR.RORCRHR_TERM_CODE' NOPRINT
BY 'RORCRHR.RORCRHR.AIDY1'
WHERE RORCRHR.RORCRHR.RORCRHR_TERM_CODE EQ '&TERM';
ON TABLE HOLD AS HOLDAIDY FORMAT ALPHA
END
-RUN
-READ HOLDAIDY,&AIDY1.A10
-IF &IORETURN NE 0 GOTO ENDIT;
-SET &AIDY = EDIT(&AIDY1,'$$$$$$9999');
-ENDIT;
END
This -INCLUDE takes the parm &TERM and builds an amper variable &AIDY to be used in logic following. Thanks again. Your help is always valuable. Paul
Prod: WF 7.7.05, BID, MRE, 7.7.06M Server, Windows 2008, RedHat, Oracle 11gR1, MS Office 2010 Test: I wish we had one!
Actually I think checking the manual is always a good idea.
You don't want to start up some nasty habits. From my experience they become "standard code" and then get caught out in later releases with code tightening.
Also if the documnented code does not work, then techsupport will have to listen to you.