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 AM EXECUTING A STORED PROCEDURE THAT PRODUCES A DATE. DATE IS IN LONG FORMAT THOUGH, AND I ONLY WANT MM/DD/YYYY TO USE. SEE CODE BELOW. IT SEEMS TO DO THE JOB IN FORMATTING IT THE WAY I WANT IT. MY QUESTION IS, I WANT TO HOLD THE RESULT IN A VARIABLE (&) TO USE IN AN HTML FORM. HOW CAN I GET THE VALUE P_DATE_OUT_FORMAT FROM THE DEFINE INTO A &VARIABLE??
TABLE FILE ARB_PKG_SUBTRACT_BUS_DAYS PRINT P_DATE_OUT ON TABLE HOLD AS P_DATE_OUT WHERE P_DATE EQ DT(&YYMD); WHERE P_ADD_NUM EQ 1; END
DEFINE FILE P_DATE_OUT P_DATE_OUT_FORMAT/MDYY=HDATE(P_DATE_OUT, 'YYMD'); ENDThis message has been edited. Last edited by: Kerry,
Version: 8.0.0.6 Windows platform All output formats will probably be used.
-SET &ECHO=ALL;
SET HOLDFORMAT=ALPHA
SET HOLDLIST=PRINTONLY
-RUN
-*-- PREPARE DATE-TIME COLUMN FOR TESTING
-SET &DTTM = &YYMD | EDIT(&TOD, '99$99$99');
DEFINE FILE CAR
TEST_DT1/HYYMDS WITH COUNTRY = HINPUT(14, '&DTTM', 8, 'HYYMDS');
END
-*-- RETRIEVE ONLY DATE PORTION AND FORMAT WITH SLASHES
TABLE FILE CAR
PRINT
COMPUTE TEST_DT1_FMT1/A8MDYY = HDATE(TEST_DT1, 'MDYY'); NOPRINT
COMPUTE TEST_DT1_FMT2/A10 = EDIT(TEST_DT1_FMT1,'99/99/9999');
WHERE RECORDLIMIT EQ 1
ON TABLE HOLD AS H001
END
-RUN
-READ H001 &TEST.A10.
-TYPE &TEST
This message has been edited. Last edited by: Francis Mariani,
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
DEFINE FILE CAR TEST_DT1/HYYMDS WITH COUNTRY = HINPUT(14, '&DTTM', 8, 'HYYMDS'); END
-*-- Retrieve only date portion and format with slashes TABLE FILE CAR PRINT COMPUTE TEST_DT1_FMT1/A8MDYY = HDATE(TEST_DT1, 'YYMD'); NOPRINT COMPUTE TEST_DT1_FMT2/A10 = EDIT(TEST_DT1_FMT1,'99/99/9999'); WHERE RECORDLIMIT EQ 1 ON TABLE HOLD AS H001 END -RUN
-READ H001 &TEST.A10. -TYPE &TEST
ALMOST WORKING - BUT....THIS IS A STORED PROCEDURE THAT TAKES 2 INPUT VALUES AND GIVES ONE OUTPUT VALUE.
INPUT IS WHERE P_DATE EQ DT(&YYMD); WHERE P_ADD_NUM EQ 1;
OUTPUT IS P_DATE_OUT;
Version: 8.0.0.6 Windows platform All output formats will probably be used.