I've searched this forum high and low and can't seem to find a formula that will extract the month number from the current date. Does anhybody have some code?This message has been edited. Last edited by: Ted Michalski,
7.7.02 Windows EXCEL, PDF, CSV, TEXT
September 15, 2010, 06:29 AM
it might be a smart idea for you to buy a nice book called "(Almost) 1001 Ways to Work with DATES in WebFOCUS" ISBN 978-0-9791722-1-2 It cost maybe 25 U$ and is worth all that dollars.
To answer your question
&YMD gives you the current DATE
&DATEM gives the month number &DATEMTR gives MONTH &DATEMtr gives Month &DATEMT gives M
And there are some more (page 46 of the mentioned book)
In total there are 61 different amper values reprecenting something about the actual system date in different formats.
prod: WF 7.6.10 platform Windows, databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7 test: WF 7.6.10 on the same platform and databases,IE7
September 15, 2010, 04:39 PM
Also, it depends on what the format of the date is.
If its just getting the current date, then follow Franks suggestion.
If its from a DB, then the format of the date will determine the function used.
HTML, PDF, Excel, PPT
In Focus since 1984
Know The Code
September 15, 2010, 04:49 PM
I don't go anywhere without that book. It has saved me many times. If you don't listen to anything else any one say, do as Frank says and order the book!
In FOCUS Since 1990 Production 8.2 Windows
September 17, 2010, 09:14 PM
Ditto on the "(Almost) 1001 Ways to Work with DATES in WebFOCUS" note. I have it and will say that it is worth having. Albeit I've not quite used all 1001 things nor do I see the need ... Yet...
In FOCUS Since 1983 ~ from FOCUS to WebFOCUS. Current: WebFOCUS Administrator at FIS Worldpay | 8204, 8206