Focal Point Banner
Community Center Education Summit Technical Support User Groups
Let's Get Social!

Facebook Twitter LinkedIn YouTube
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Alpha to numeric date conversion?
Go
New
Search
Notify
Tools
Reply
  
Alpha to numeric date conversion?
 Login/Join
 
<MikeR>
posted
I have a frontend program that is passing a date as alpha MM/DD/CCYY to a WebFOCUS program. I need to convert that to a numeric CCYYMMDD format to use in a WHERE statement. I tried:

AND ( SERVICEDT GE
(DATECVT(&SRVDTLO, 'M/D/YY', 'YYMD'))
)

but don't get the correct results. Do I need to specify numeric somehow? Is there a way to use -TYPE or some other command to see what it's converting to?

Any suggestions would be appreciated.

Mike R
 
Reply With QuoteReport This Post
Guru
posted Hide Post
Here's one way:
-SET &IN_DATE = EDIT(&DATEMDYY,'$$$$$$9999') | EDIT(&DATE,'99$99');
-TYPE &IN_DATE
Not real slick but it works. It does assume that month and day are ALWAYS two digits.
 
Posts: 252 | Location: USA | Registered: April 15, 2003Reply With QuoteReport This Post
<MikeR>
posted
That does it. Thank you very much.
 
Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Alpha to numeric date conversion?

Copyright © 1996-2018 Information Builders, leaders in enterprise business intelligence.