|
Hi all, It used to be that I could count on DSPPGMREF giving a fairly accurate picture of what files an RPG program updates, and I would have sworn that it wasn't possible to use a 'U' or 'A' on an F-spec, without actually coding them somewhere in the program. However, I wrote a very small program that refers to an external file, but doesn't make any use of file I/O. No READ/WRITE/UPDATE opcodes of any kind. There aren't _any_ file opcodes in this program that refer to the file listed on the F-spec. Used to be RPG would complain about that. Why not now? Interesting fact - The below code insists on opening the file. Unused files ought to be 'compiled out'. Why open a file that the program cannot possibly read or write or update? And, the big bummer, DSPPGMREF shows that the file is used for input, output, and update. In fact - it's not used for anything at all. Surely this can't be WAD? Thanks. 5722WDS V5R1M0 010525 RN IBM ILE RPG WMCMODHMH/TESTPFR ******** 06/09/05 14:45:01 Page 1 Command . . . . . . . . . . . . : CRTBNDRPG Issued by . . . . . . . . . . : ******** Program . . . . . . . . . . . . : TESTPFR Library . . . . . . . . . . . : ******** Text 'description' . . . . . . . : *SRCMBRTXT Source Member . . . . . . . . . : TESTPFR Source File . . . . . . . . . . : ORSRC4.2 Library . . . . . . . . . . . : ******** CCSID . . . . . . . . . . . . : 37 Text 'description' . . . . . . . : Last Change . . . . . . . . . . : 06/09/05 14:44:59 Generation severity level . . . : 10 Default activation group . . . . : *YES Compiler options . . . . . . . . : *XREF *GEN *NOSECLVL *SHOWCPY *EXPDDS *EXT *NOSHOWSKP *NOSRCSTMT *DEBUGIO *NOEVENTF Debugging views . . . . . . . . : *STMT Output . . . . . . . . . . . . . : *PRINT Optimization level . . . . . . . : *NONE Source listing indentation . . . : *NONE Type conversion options . . . . : *NONE Sort sequence . . . . . . . . . : *HEX Language identifier . . . . . . : *JOBRUN Replace program . . . . . . . . : *YES User profile . . . . . . . . . . : *USER Authority . . . . . . . . . . . : *LIBCRTAUT Truncate numeric . . . . . . . . : *YES Fix numeric . . . . . . . . . . : *NONE Target release . . . . . . . . . : *CURRENT Allow null values . . . . . . . : *NO Define condition names . . . . . : *NONE Enable performance collection . : *PEP Profiling data . . . . . . . . . : *NOCOL Licensed Internal Code options . : 5722WDS V5R1M0 010525 RN IBM ILE RPG ********/TESTPFR ******** 06/09/05 14:45:01 Page 2 Line <---------------------- Source Specifications ----------------------------><---- Comments ----> Do Page Change Src Seq Number ....1....+....2....+....3....+....4....+....5....+....6....+....7....+....8....+....9....+...10 Num Line Date Id Number S o u r c e L i s t i n g 1 Ftestpf uf a e disk 050609 000100 2 /free 050609 000200 *--------------------------------------------------------------------------------------------* * RPG name External name * * File name. . . . . . . . . : TESTPF ********/TESTPF * * Record format(s) . . . . . : TESTR TESTR * *--------------------------------------------------------------------------------------------* 3=ITESTR 1000001 *--------------------------------------------------------------------------------------------* 1 * RPG record format . . . . : TESTR * 1 * External format . . . . . : TESTR : ********/TESTPF * 1 *--------------------------------------------------------------------------------------------* 1 4=I A 1 1 FIELD00 1000002 5=I A 2 2 FIELD01 1000003 6=I A 3 3 FIELD02 1000004 7=I A 4 4 FIELD03 1000005 8 *inlr = '1'; 050609 000300 9 /end-free 050609 000400 * * * * * E N D O F S O U R C E * * * * * 5722WDS V5R1M0 010525 RN IBM ILE RPG ********/TESTPFR ******** 06/09/05 14:45:01 Page 3 A d d i t i o n a l D i a g n o s t i c M e s s a g e s Msg id Sv Number Seq Message text *RNF7066 00 1 000100 Record-Format TESTR not used for input or output. * * * * * E N D O F A D D I T I O N A L D I A G N O S T I C M E S S A G E S * * * * * 5722WDS V5R1M0 010525 RN IBM ILE RPG ********/TESTPFR ******** 06/09/05 14:45:01 Page 4 C r o s s R e f e r e n c e File and Record References: File Device References (D=Defined) Record TESTPF DISK 1D TESTR 1 3 Global Field References: Field Attributes References (D=Defined M=Modified) *INLR N(1) 8M *RNF7031 FIELD00 A(1) 4D *RNF7031 FIELD01 A(1) 5D *RNF7031 FIELD02 A(1) 6D *RNF7031 FIELD03 A(1) 7D Indicator References: Indicator References (D=Defined M=Modified) LR 8M * * * * * E N D O F C R O S S R E F E R E N C E * * * * * 5722WDS V5R1M0 010525 RN IBM ILE RPG ********/TESTPFR ******** 06/09/05 14:45:01 Page 5 E x t e r n a l R e f e r e n c e s Statically bound procedures: Procedure References No references in the source. Imported fields: Field Attributes Defined No references in the source. Exported fields: Field Attributes Defined No references in the source. * * * * * E N D O F E X T E R N A L R E F E R E N C E S * * * * * 5722WDS V5R1M0 010525 RN IBM ILE RPG ********/TESTPFR ******** 06/09/05 14:45:01 Page 6 M e s s a g e S u m m a r y Msg id Sv Number Message text *RNF7031 00 4 The name or indicator is not referenced. *RNF7066 00 1 Record-Format name of Externally-Described file is not used. * * * * * E N D O F M E S S A G E S U M M A R Y * * * * * 5722WDS V5R1M0 010525 RN IBM ILE RPG ********/TESTPFR ******** 06/09/05 14:45:01 Page 7 F i n a l S u m m a r y Message Totals: Information (00) . . . . . . . : 5 Warning (10) . . . . . . . : 0 Error (20) . . . . . . . : 0 Severe Error (30+) . . . . . . : 0 --------------------------------- ------- Total . . . . . . . . . . . . . : 5 Source Totals: Records . . . . . . . . . . . . : 9 Specifications . . . . . . . . : 7 Data records . . . . . . . . . : 0 Comments . . . . . . . . . . . : 0 * * * * * E N D O F F I N A L S U M M A R Y * * * * * Program TESTPFR placed in library ********. 00 highest severity. Created on 05/06/09 at 14:45:02. * * * * * E N D O F C O M P I L A T I O N * * * * * Regards, Rich
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.