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     -WRITE on AS400 WebFOCUS

Read-Only Read-Only Topic
Go
Search
Notify
Tools
-WRITE on AS400 WebFOCUS
 Login/Join
 
Master
posted
Has anybody used -WRITE to update (APPEND to an AS400 flat file? Is there something special I need to do?


Pat
WF 7.6.8, AIX, AS400, NT
AS400 FOCUS, AIX FOCUS,
Oracle, DB2, JDE, Lotus Notes
 
Posts: 755 | Location: TX | Registered: September 25, 2007Report This Post
Expert
posted Hide Post
Did you put the (APPEND on the filedef?


Ginny
---------------------------------
Prod: WF 7.7.01 Dev: WF 7.6.9-11
Admin, MRE,self-service; adapters: Teradata, DB2, Oracle, SQL Server, Essbase, ESRI, FlexEnable, Google
 
Posts: 2723 | Location: Ann Arbor, MI | Registered: April 05, 2006Report This Post
Master
posted Hide Post
My code

 
FILEDEF FOCAUDIT DISK RS6000/FOCAUDIT ( APPEND
-RUN
-* -SET &ECHO=ALL;
-SET &AUDIT_TIME = EDIT('&TOD.EVAL','99$99$99');
-SET &AUDIT_DATE = '&YYMD.EVAL'|'&AUDIT_TIME.EVAL';
-DEFAULT &AUDIT_USER='ouruser';
-SET &AUDIT_USER = GETUSER('A8');
-* -SET &AUDIT_FEX  = '&FEX.EVAL';
-SET &AUDIT_SRVR='400SRV';
-RUN

-WRITE FOCAUDIT  &AUDIT_DATE  &AUDIT_FEX  &AUDIT_USER  &AUDIT_SRVR
-RUN

 

This message has been edited. Last edited by: PBrightwell,


Pat
WF 7.6.8, AIX, AS400, NT
AS400 FOCUS, AIX FOCUS,
Oracle, DB2, JDE, Lotus Notes
 
Posts: 755 | Location: TX | Registered: September 25, 2007Report This Post
Expert
posted Hide Post
Hi Pat,

Ginny is not on, so, I hope she doesn't mind...

Your dataset name should have a suffix, and, you'll need write access on it:

FILEDEF FOCAUDIT DISK RS6000/FOCAUDIT.dat or .ftm or .txt (APPEND

Tom


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1972 | Location: Centennial, CO | Registered: January 31, 2006Report This Post
Gold member
posted Hide Post
Not sure about the AS400. But on an AIX box, I've found that a -RUN closes and reopens the output file... thus overlaying what was previously there. Is that what you are experiencing?

-Diptesh Patel


Diptesh
WF 7.1.7 - AIX, MVS
 
Posts: 79 | Location: Warren, NJ, USA | Registered: October 25, 2006Report This Post
Expert
posted Hide Post
This looks like MRE, so, you may need:

APP FI FOCAUDIT DISK RS6000/FOCAUDIT.dat or .ftm or .txt (APPEND


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1972 | Location: Centennial, CO | Registered: January 31, 2006Report This Post
Master
posted Hide Post
Tom,

The file extention doesn't apply on AS400, that's a pc/unix thing- none of our AS400 files has an extention.

Diptesh,

This same fex works on the AIX (UNIX with the UNIX path of course). Without the -RUN after the FILEDEF I get a message saying it isn't filedef'd


Pat
WF 7.6.8, AIX, AS400, NT
AS400 FOCUS, AIX FOCUS,
Oracle, DB2, JDE, Lotus Notes
 
Posts: 755 | Location: TX | Registered: September 25, 2007Report This Post
Virtuoso
posted Hide Post
Pat,
You do need to have a a value for &AUDIT_FEX, since you write it out. But you had it commented, which may lead to unwanted results. The -RUN after the filedef is needed, but the one after the -SET's is not. The code would look like:
APP FI FOCAUDIT DISK RS6000/FOCAUDIT (APPEND
-RUN
-* -SET &ECHO=ALL;
-SET &AUDIT_TIME = EDIT('&TOD.EVAL','99$99$99');
-SET &AUDIT_DATE = '&YYMD.EVAL'|'&AUDIT_TIME.EVAL';
-DEFAULT &AUDIT_USER='WFOCUS';
-SET &AUDIT_USER = GETUSER('A8');
-SET &AUDIT_FEX  = '&FEX.EVAL';
-SET &AUDIT_SRVR='400SRV';

-WRITE FOCAUDIT  &AUDIT_DATE  &AUDIT_FEX  &AUDIT_USER  &AUDIT_SRVR
-RUN

But, is there some error that you receive or any undesired reuslts?


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report This Post
Master
posted Hide Post
This is an online server procedure executed from our intranet interface. The &AUDIT_FEX is set in the individual program and this is -INCLUDEd. I -TYPEd my variables to be sure all had values and they are:

20090421080617 amd018a WFOCUS 400SRV

I also tried the AP FI instead of the FILEDEF with the same results. The message I am getting is somewhat meaningless it is

(FOC325) ERROR WRITING FILE NAMED: FOCAUDIT 1


Pat
WF 7.6.8, AIX, AS400, NT
AS400 FOCUS, AIX FOCUS,
Oracle, DB2, JDE, Lotus Notes
 
Posts: 755 | Location: TX | Registered: September 25, 2007Report 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     -WRITE on AS400 WebFOCUS

Copyright © 1996-2020 Information Builders