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 know there are a lot of discussions on this, but i haven't found dates the way they are in our system.
Our date is stored into an P9 YYYYMMDD, i would like to subtract that date from current date to get number of days, and also from another date in the same record.
Also, I'm looking to add current date to the WHERE statement in the P9 format.
Please Help.This message has been edited. Last edited by: Joe Beydoun,
version 8202M Reporting Server on Windows Server using DB2 Connect to access data from iseries.
Our date is stored into an P9 YYYYMMDD, i would like to subtract that date from current date to get number of days, and also from another date in the same record.
Also, I'm looking to add current date to the WHERE statement in the P9 format.
Please Help.
use the Funtion AYMD (YYYYMMDD, amount of days, 'YYYYMMDD')
Regarding conversion of your numeric date-time to alphanumeric, try function FPRINT. Search this forum for FPRINT. The most recent entry will give you the syntax for FPRINT (which is apparently mostly undocumented!). After conversion to alphanumeric, you can format it with the EDIT function.
WebFOCUS 7.7.05
Posts: 1213 | Location: Seattle, Washington - USA | Registered: October 22, 2007
(Almost) 1001 Ways to Work With Dates for WebFOCUS This reference manual explains the date-related functions of WebFOCUS as well as the several, different types of dates supported by WebFOCUS. The specific functions and methods used vary depending on the type of date involved. Preview a sample of (Almost) 1001 Ways to Work With Dates for WebFOCUS.
jimster06 DevStu WF 7.6.11 W7 HTML, PDF, EXL2K
Posts: 252 | Location: USA | Registered: April 15, 2003
Just as Waz suggests, use a combination of PTOA to transfer your Packed decimal to Alpha and then use HINPUT -
DEFINE FILE CAR
INPUTDT/P15 = 20110524171520;
INPUTDTA/A17 = PTOA(INPUTDT, '(P15)', 'A17');
DT_FROM_ALPHA/HYYMDS = HINPUT(17, INPUTDTA, 8, 'HYYMDS');
END
TABLE FILE CAR
PRINT INPUTDT
INPUTDTH
DT_FROM_ALPHA
BY COUNTRY
IF RECORDLIMIT EQ 1
END
You can then use functions such as HPART to get the components, HDIFF to get differences for various components (Months, Days, Weeks etc.)
To get the current date into datetime format you can just use the same sort of DEFINE using a variable such as - -SET &TodayH = &YYMD || EDIT(&TOD,'99$99$99');
TThis message has been edited. Last edited by: Tony A,
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004