Focal Point Banner


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.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] Convert character (A8) to date format

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Convert character (A8) to date format
 Login/Join
 
Member
posted
I am in Oracle 11g and working with AppStudio 82.

One for the date fields comes in from Oracle as a YYYYMMDD in character format, but I need to convert it to a date field in AS.

Is there a function i can't find that might do this for me?

This message has been edited. Last edited by: FP Mod Chuck,


John Coleman
WEBFocus 8.1.05
Windows 7
 
Posts: 20 | Location: Rensselaer, NY | Registered: May 20, 2016Report This Post
Platinum Member
posted Hide Post
You could try HINPUT...

https://webfocusinfocenter.inf...ng/source/hinput.htm


JC
WebFOCUS Dev Studio / App Studio
8.2.01
Windows 7
 
Posts: 146 | Registered: November 09, 2015Report This Post
Member
posted Hide Post
Than you. I should have said that in the post. I tried that but it was so poorly un-optimized that I couldn't go forward with it in production. I'll keep poking. Thank you for your answer though!


John Coleman
WEBFocus 8.1.05
Windows 7
 
Posts: 20 | Location: Rensselaer, NY | Registered: May 20, 2016Report This Post
Silver Member
posted Hide Post
Have you tried to convert using DATECVT instead? It works for date only and does not require the time portion to be in the date. might work better.

https://webfocusinfocenter.inf...9b-B343-9B01F25A24F0

you could always just convert it to an integer of I8YYMD.


WebFOCUS 8.2.02M
Windows
Server/8.2.02M
All Outputs
 
Posts: 43 | Location: Odessa, Florida | Registered: July 26, 2011Report This Post
Expert
posted Hide Post
How are you using the function? I assume it's in a DEFINE, therefore applies to every row. Try it in a COMPUTE, it will then be applied to the answer set.


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
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Guru
posted Hide Post
or if you're using it in a filter, the SQL is probably not optimized. Could you post the code to have a better understanding?


Test: WF 8.2
Prod: WF 8.2
DB: Progress, REST, IBM UniVerse/UniData, SQLServer, MySQL, PostgreSQL, Oracle, Greenplum, Athena.
 
Posts: 454 | Location: Europe | Registered: February 05, 2007Report This Post
Master
posted Hide Post
John,

Another option if you are concerned with inefficiencies from WF would be to create a virtual field on the table in Oracle and do the conversion there. That way you aren't worrying about creating a define every time. then in the masterfile make sure the Actual value is date and usage is YYMD. Then your all set.


Eric Woerle
8.1.05M Gen 913- Reporting Server Unix
8.1.05 Client Unix
Oracle 11.2.0.2
 
Posts: 750 | Location: Warrenville, IL | Registered: January 08, 2013Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] Convert character (A8) to date format

Copyright © 1996-2020 Information Builders