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     [CLOSED]Month in alphanumeric from a date field

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED]Month in alphanumeric from a date field
 Login/Join
 
Platinum Member
posted
I have tried using the HName to pull the month from a date and have been unable to get it to work.

I am able to pull the month in Integer using DPART but they really want the Month in words rather than numbers.

This message has been edited. Last edited by: <Emily McAllister>,


Prod: WebFOCUS 8.2.0.4
OS: Windows
Outputs: HTML, PDF, Excel, PPT
In Focus since 2005
 
Posts: 121 | Registered: November 17, 2005Report This Post
Guru
posted Hide Post
please post the code that doesn't work. I have used 'HNAME' and it works.


WF 7.6.11
Oracle
WebSphere
Windows NT-5.2 x86 32bit
 
Posts: 398 | Registered: February 04, 2008Report This Post
Platinum Member
posted Hide Post
MTH/A10=HNAME(today,'MONTH','A10')


Error:
Invalid Type Of Argument #1 for user Function HName


Prod: WebFOCUS 8.2.0.4
OS: Windows
Outputs: HTML, PDF, Excel, PPT
In Focus since 2005
 
Posts: 121 | Registered: November 17, 2005Report This Post
Virtuoso
posted Hide Post
What's the format of today field?


WebFOCUS 8206, Unix, Windows
 
Posts: 1853 | Location: New York City | Registered: December 30, 2015Report This Post
Expert
posted Hide Post
HNAME requires the date to be date-time format.

TABLE FILE CAR
PRINT
COUNTRY NOPRINT
COMPUTE HTODAY/HYYMD = HDTTM('&YYMD', 8, 'HYYMD');
COMPUTE MTH/A10=HNAME(HTODAY,'MONTH','A10');
WHERE RECORDLIMIT EQ 1
END


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
Expert
posted Hide Post
If you're brave, you can try it in one statement:

TABLE FILE CAR
PRINT
COUNTRY NOPRINT

COMPUTE MTH/A10=HNAME( HDTTM('&YYMD', 8, 'HYYMD'), 'MONTH', 'A10');

WHERE RECORDLIMIT EQ 1
END


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
Master
posted Hide Post
Why bother converting it at all? There is a data type for the month name. Mtr

 TABLE FILE YOUR_TABE
SUM YOUR_DATE/Mtr
BY YOUR_DATE
END
  


You can also use the FPRINT function to convert it to alpha if needed, but if you just want to display it, I wouldn't bother converting it from a smart date.


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     [CLOSED]Month in alphanumeric from a date field

Copyright © 1996-2020 Information Builders