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     functions in webfocus

Read-Only Read-Only Topic
Go
Search
Notify
Tools
functions in webfocus
 Login/Join
 
Silver Member
posted
im kinda new to webfocus and was wondering how to make a function. This is what i want in my function. I use this segment of code many times and wanted to know how i could save a lot of space by just calling CONVERT(MONTH) for example.

IF &ENDMONTH EQ '1' THEN 'January '
ELSE IF &ENDMONTH EQ '2' THEN 'February '
ELSE IF &ENDMONTH EQ '3' THEN 'March '
ELSE IF &ENDMONTH EQ '4' THEN 'April '
ELSE IF &ENDMONTH EQ '5' THEN 'May '
ELSE IF &ENDMONTH EQ '6' THEN 'June '
ELSE IF &ENDMONTH EQ '7' THEN 'July '
ELSE IF &ENDMONTH EQ '8' THEN 'August '
ELSE IF &ENDMONTH EQ '9' THEN 'September '
ELSE IF &ENDMONTH EQ '10' THEN 'October '
ELSE IF &ENDMONTH EQ '11' THEN 'November '
ELSE IF &ENDMONTH EQ '12' THEN 'December ';
 
Posts: 38 | Registered: October 10, 2006Report This Post
Expert
posted Hide Post
The WebFOCUS Function Reference manual has a chapter called "Creating a Subroutine", and interestingly, they use, as an example, what you want to do: "Using a Custom Subroutine: The MTHNAM Subroutine".


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
Virtuoso
posted Hide Post
there are many roads leading to Rome....

1) go for a basic training
2) download the documentation (and read it)
3) search here with "find"
4) ask us....

you can use the formula MONTH/TRM=DATE;




Frank

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

 
Posts: 2387 | Location: Amsterdam, the Netherlands | Registered: December 03, 2006Report This Post
Master
posted Hide Post
you can use this also,

-SET &EM=DECODE &ENDMONTH('1' 'JANUARY' '2' 'FEBRUARY' '3' 'MARCH' '4' 'APRIL' '5' 'MAY' '6' 'JUNE' '7' 'JULY' '8' 'AUGUST' '9' 'SEPTEMBER' '10' 'OCTOBER' '11' 'NOVEMBER' '12' 'DECEMBER');


WFConsultant

WF 8105M on Win7/Tomcat
 
Posts: 780 | Location: Florida | Registered: January 09, 2005Report This Post
Guru
posted Hide Post
You may also want to lookup:

-INCLUDE filename


Glenda

In FOCUS Since 1990
Production 8.2 Windows
 
Posts: 301 | Location: Galveston, Texas | Registered: July 07, 2004Report 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     functions in webfocus

Copyright © 1996-2020 Information Builders