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] Test if APP command was successful

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] Test if APP command was successful
 Login/Join
 
Master
posted
Anyone know how to test to see if a call to an APP command like APP COPYFILE was successful?

This message has been edited. Last edited by: <Kathryn Henning>,




Scott

 
Posts: 865 | Registered: May 24, 2004Report This Post
Expert
posted Hide Post
APP COPYFILE IBISDAMP FLOWDESC.XSD DEFAULT  TDEST FLOWDESC.XSD DEFAULT
-RUN

-TYPE &FOCERRNUM


This results in '36307' so I know that an error occurred... Perhaps testing &FOCERRNUM after a -RUN will suffice.


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
Platinum Member
posted Hide Post
You don't list your platform in your post but if you are running on a Windows box, you could check for the file existence after the copy with the DOS STATE command then poll the value of &RETCODE. &RETCODE = 0 on success and -1 otherwise.

I suppose that if the target file exists prior to the copy that you would need to delete it, then copy the new file, and then check if it exists in the target location.

APP DELETEF ...
APP COPYF ...
DOS STATE file
-IF &RETCODE EQ 0 THEN .... ELSE...;

Hope that helps,

Norb


prod:7.6.9, win2k3 mre, caster, bid, devstudio 7.6.9
 
Posts: 242 | Location: Minneapolis | Registered: February 16, 2006Report This Post
Master
posted Hide Post
Testing &FOCERRNUM does not always return an error. If the app folder is not there an error will be returned if the file is not there it does not seem to return an error. Want to get rid of all DOS commands that this can be a big security hole.




Scott

 
Posts: 865 | Registered: May 24, 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     [CLOSED] Test if APP command was successful

Copyright © 1996-2020 Information Builders