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'm not sure where to look for information on this...
I'd like to convert a numeric field to a webfocus date in a compute/define. It's 8 digits, YYYYMMDD.
What function does this? Is there something simple like oracle's to_date? Or do I have to typecast to a string, substr out the year, month and date seperately then feed them back into a function or something?
Thanks!
Prod: Single Windows 2008 Server running Webfocus 7.7.03 Reporting server Web server IIS6/Tomcat, AS400 DB2 database.
You would think that the compute for DT4 would work - you want to convert a date field into a date-time field, but it doesn't work - that would be too easy.
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
You can't eliminate the compute if there is already a numeric field that needs to be converted to a date field. The existing field has to be converted to an I8YYMD field before being converted to a date field.
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
I find it intersting that everyone seems to be obsessed with using the integer date to begin with and then converting to a smart-date, or if need be, directly to the date-timestamp using the DT function?
Why not go directly to the smart-date?
TABLE FILE CAR SUM COMPUTE MYSMARTDATE/YYMD = '20071108'; COMPUTE MYDATESTAMP/HYYMDS = DT(20071108); BY COUNTRY END
Windows: WF 7.6.2: SQL Server 2008 R2
Posts: 86 | Location: Chicago | Registered: August 03, 2007
Well, the original question did start with "I'd like to convert a numeric field to a webfocus date".
If you have a field in a table (that you cannot modify, or modify the master for) that contains a date, but is defined as a numeric field, you would have to do what we've been talking about here.
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
I agree. I don't know why the length of the string to be manipulated needs to be passed - the function should be able to figure that out, that's how it's done in almost all the other languages I've worked with.
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
Well it looks like another runaway thread. I just do not understand, if someone ask for help and someone suggest a soluation and it works even thought it can be done differently without any performance gain. Then way does everyone have to try and show up some else. Maybe it is just to get there karma increased I don't know, but I got another point.