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.



Read-Only Read-Only Topic
Go
Search
Notify
Tools
FOCERRNUM
 Login/Join
 
Member
posted
Good day,

I have managed to peform error handling in our application using the good old code here:

-IF &FOCERRNUM NE 0 GOTO FATAL;

Furthermore, I am able to get the 'generic' error description: FEXERR(&FOCERRNUM,'A72');

IS there a way (or a variable) similar to FOCERRNUM that will give me the Error description and NOT the general one from FEXERR.

For example:
FOCERRNUM: 205
FEXERR: (FOC205) THE DESCRIPTION CANNOT BE FOUND FOR FILE NAMED:

FOCERRDESC: (FOC205) THE DESCRIPTION CANNOT BE FOUND FOR FILE NAMED: LOST_MASTER_FILE

To summarize, I am trying to Capture the Error description "as the error occurs", the same way we can capture the error number using FOCERRNUM.


WebFOCUS 52 and 53
Test: WebFOCUS 764
Unix
Output: Excel, HTML, Text, PDF
 
Posts: 3 | Registered: January 28, 2008Report This Post
Expert
posted Hide Post
I haven't found a way yet.


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
I'd like to know this as whenever i get an error i have to rerun using this:

? (errornumber)

ie:

? 205

to get a full description:

0(FOC205) THE DESCRIPTION CANNOT BE FOUND FOR FILE NAMED:
No data description can be found for the file requested. Check the
Master File Descriptions allocated or available, or the spelling of
the file name. If you are in Screen Painter, type IGNore to
continue, or any other input to return to TED.

so the ability to code this into the -IF &FOCERRNUM NE 0 GOTO ERROR; would be good if purely for effiency reasons...

im quite new to WF so haven't really played with the -IF &FOCERRNUM NE 0 GOTO ERROR; command just use dthe existing code our developers use for error trapping.


Developer Studio 7.64
Win XP
Output: mostly HTML, also Excel and PDF

"Never attribute to malice that which can be adequately explained by stupidity." - Heinlein's Razor
 
Posts: 285 | Location: UK | Registered: October 26, 2007Report This Post
Master
posted Hide Post
Have you tried this?

-IF &FOCERRNUM NE 0 GOTO FATAL;
.
.
.
-FATAL
-SET &ERRNUM=&FOCERRNUM;
? &ERRNUM
-RUN
.
.
.


In FOCUS since 1985. Prod WF 8.0.08 (z90/Suse Linux) DB (Oracle 11g), Self Serv, Report Caster, WebServer Intel/Linux.
 
Posts: 975 | Location: Oklahoma City | Registered: October 27, 2006Report This Post
Member
posted Hide Post
jgelona,

The outcome of the code you suggested is similar to the outcome of:

FEXERR(&FOCERRNUM,'A72');

Though this is an excellent way to acquire more information about a particular error, it does not answer my original question:

How to capture an error description "as it occurs" similar to how we capture the Error number using FOCERRNUM. Perhaps another variable called FOCERRDESC.


WebFOCUS 52 and 53
Test: WebFOCUS 764
Unix
Output: Excel, HTML, Text, PDF
 
Posts: 3 | Registered: January 28, 2008Report This Post
Expert
posted Hide Post
-SET &FOCERRDESC=FEXERR(&FOCERRNUM,'A72');
-TYPE &FOCERRDESC
or write it to a file .
or write it to the heading of a report and email it... or...whatever you need.
It seems to me you've answered your own question.
What am i missing?




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
 
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003Report This Post
Virtuoso
posted Hide Post
Susannah,

The difference is that specific information is missing. The example given at the beginning of the post is a good example. The WebFOCUS generic error msg simply states an MFD was not found but a more specific error msg would also include the name on the MFD which was not found at the time a read was attempted.

Another example would be to get an error msg that says FIELDNAME NOT RECOGNIZED vesus FIELDNAME NOT RECOGNIZED: THEFIELDNAME.

See the difference?


Thanks!

Mickey

FOCUS/WebFOCUS 1990 - 2011
 
Posts: 995 | Location: Gaithersburg, MD, USA | Registered: May 07, 2003Report This Post
Expert
posted Hide Post
oh yeah, i see.




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
 
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003Report This Post
Virtuoso
posted Hide Post
The only time the specific information you're looking for is available, is when the error occurs. No sooner,no later.
There is only one place where this error message will be recorded, apart from sysout, and you will have to enable it to get it there: the server traces.
Now the good thing about traces is that you can hev them generated on demand and have them written to a file of your choice.
Possible scenario to get what you want:
1. start fex
2. within the fex turn on server tracing.
3. If an error occurs, you can trap it with &focerrnum.
4. disable traces
5. Table the trace file, looking for a line that contains your error message number.
This, to my knowledge, is the only, albeit somewhat farfetched, way of getting the error specifics.

Hope this helps...


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic


Copyright © 1996-2020 Information Builders