AS/400 Subfile Program

470 pts.
Tags:
AS/400 programming
AS/400-Subfile Programming
AS400 Subfile
A)I have a physical file named E0003 its source code is
[p style="margin-bottom:0in;margin-bottom:.0001pt;line-height: normal;mso-pagination:none;mso-layout-grid-align:none;text-autospace:none" class="MsoNormal">                                            UNIQUE  [span style="font-size:10.0pt;line-height:115%;font-family:"Arial","sans-serif"; mso-fareast-font-family:"Times New Roman";mso-fareast-theme-font:minor-fareast; mso-ansi-language:EN-US;mso-fareast-language:EN-US;mso-bidi-language:AR-SA">   20     vimal            testengineer              30,000 
 when i run my subfile program A60 it Gives severity level 30 error
QRG7030 Severity:  30   Number:    1                              
        Message . . . . :   The Field or indicator is not defined.
 5722WDS V5R3M0  030905     
* 7030  07            3010  
i can't find out the solution please guide me.
Actually my requirement is to load all the records from physical file E0003 to the display file in Subfile record format SFL03 and if we want to view one particular record alone means we should get it in a single record format display file DD,
if we want to change or update records means we should do it in another single record format display file DD1 and using it except EMID we should edit all the fields and the same should be displayed in Subfile record format SFL03 and same should be updated in physical file E0003 also kindly tell me the solution.
My display file E3 record formats are given below
                                                                 
         10    SFL03         SFL                         01/18/11
         20    CTL03         SFLCTL    SFL03             01/18/11
         30    DD            RECORD                      01/18/11
         40    DD1           RECORD                      01/18/11
         50    FOOTER        RECORD                      01/18/11
         60    FOOTER1       RECORD                      01/18/11
                                                                 
 



Software/Hardware used:
V5R3
ASKED: January 19, 2011  1:12 PM
UPDATED: January 20, 2011  11:21 PM

Answer Wiki

Thanks. We'll let you know when a new response is added.

*7030 is a compile time error
You do not have one of the fields you are using defined in your code.
The compile error listing should give you the field name and line number of the error

Discuss This Question: 8  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • Kaly
    A)I have a physical file named E0003 its source code is UNIQUE R E0 EMID 5 0 EMNAM 15 EMDES 15 EMSAL 5 0 K EMID B) I have another display file name E3 its source code is A*%%TS SD 20110118 074242 SURESH400 REL-V5R3M0 5722-WDS A*%%EC A DSPSIZ(24 80 *DS3) A R SFL03 SFL A*%%TS SD 20110118 070616 SURESH400 REL-V5R3M0 5722-WDS A SFLNXTCHG A EMID R O 9 13REFFLD(E0/EMID SURESH4001/E0003 A EMNAM R O 9 24REFFLD(E0/EMNAM SURESH4001/E000 A EMDES R O 9 42REFFLD(E0/EMDES SURESH4001/E000 A EMSAL R O 9 64REFFLD(E0/EMSAL SURESH4001/E000 A FLD001 1 0I 9 4 A R CTL03 SFLCTL(SFL03) A*%%TS SD 20110118 070616 SURESH400 REL-V5R3M0 5722-WDS A OVERLAY A 30 SFLDSP A SFLDSPCTL A SFLSIZ(0006) A SFLPAG(0005) A 3 4'2=edit 5=view' A 7 4' OPT EMID EMNAM - A EMDES EMSAL ' A 8 7' ' A R DD A*%%TS SD 20110118 071850 SURESH400 REL-V5R3M0 5722-WDS A 4 3'emid emnam - A emdes emsal' A EMID R O 5 2REFFLD(E0/EMID SURESH4001/E0003) A EMNAM R O 5 18REFFLD(E0/EMNAM SURESH4001/E0003) A EMDES R O 5 41REFFLD(E0/EMDES SURESH4001/E0003) A EMSAL R O 5 62REFFLD(E0/EMSAL SURESH4001/E0003) A R DD1 A*%%TS SD 20110118 071850 SURESH400 REL-V5R3M0 5722-WDS A 4 4'emid emnam emdes- A emsal' A EMNAM R I 5 15REFFLD(E0/EMNAM SURESH4001/E0003) A EMDES R I 5 32REFFLD(E0/EMDES SURESH4001/E0003) A EMSAL R I 5 55REFFLD(E0/EMSAL SURESH4001/E0003) A EMID R O 5 3REFFLD(E0/EMID SURESH4001/E0003) A R FOOTER A*%%TS SD 20110118 071850 SURESH400 REL-V5R3M0 5722-WDS A 20 5'f7=confirm f3=exit' A R FOOTER1 A*%%TS SD 20110118 074242 SURESH400 REL-V5R3M0 5722-WDS A 20 5'f3=exit' C)my subfile program is A60 its source code is FE0003 UF E K DISK FE3 CF E WORKSTN F RRN KSFILE SFL03 C Z-ADD 0 RRN 40 C Z-ADD 0 OPT 20 C READ E0003 45 C *IN45 DOWEQ *OFF C RRN ADD 1 RRN C WRITE SFL03 C READ E0003 45 C ENDDO C RRN IFGT 0 C MOVE *ON *IN30 C ENDIF C WRITE FOOTER1 C EXFMT CTL03 C READC SFL03 60 C *IN60 DOWEQ *OFF C OPT IFEQ 5 C EMID CHAIN E0 58 C EXFMT DD C ENDIF C OPT IFEQ 2 C EMID CHAIN E0 48 C WRITE FOOTER C EXFMT DD1 C *IN07 IFEQ *ON C UPDAT E0 C ENDIF C ENDIF C ENDDO C SETON LR D) the records present in my physical file E0003 are EMID EMNAM EMDES EMSAL 1 sarikha manager 25,000 2 muthu sweeper 1,200 3 vicky cleaner 1,500 4 ramu operations 4,000 5 edward officeboy 5,000 6 kalyan sales 9,500 7 ramesh fpc 11,500 8 sarikha developer 14,000 9 suresh teamleader 21,000 10 rajesh developer 16,000 11 ganesh programmer 20,000 12 shankar projectmanager 30,000 13 balu driver 6,500 14 rajan cook 9,000 15 thanika steno 4,000 16 sarikha typist 5,000 17 sreesha developer 17,000 18 malathi programmer 21,000 19 amal catering 11,000 20 vimal testengineer 30,000 when i run my subfile program A60 it Gives severity level 30 error QRG7030 Severity: 30 Number: 1 Message . . . . : The Field or indicator is not defined. 5722WDS V5R3M0 030905 * 7030 07 3010 i can't find out the solution please guide me. Actually my requirement is to load all the records from physical file E0003 to the display file in Subfile record format SFL03 and if we want to view one particular record alone means we should get it in a single record format display file DD, if we want to change or update records means we should do it in another single record format display file DD1 and using it except EMID we should edit all the fields and the same should be displayed in Subfile record format SFL03 and same should be updated in physical file E0003 also kindly tell me the solution. My display file E3 record formats are given below 10 SFL03 SFL 01/18/11 20 CTL03 SFLCTL SFL03 01/18/11 30 DD RECORD 01/18/11 40 DD1 RECORD 01/18/11 50 FOOTER RECORD 01/18/11 60 FOOTER1 RECORD 01/18/11
    470 pointsBadges:
    report
  • TomLiotta
    QRG7030 Severity: 30 Number: 1 Message . . . . : The Field or indicator is not defined. 5722WDS V5R3M0 030905 * 7030 07 3010 The first lines are telling you what the error is. The last line might be telling you where the error is, but I can't recognize the format. I'm not even sure what compiler you're using. In any case, some of your problem is probably related to this line in your subfile: A FLD001 1 0I 9 4 I suspect that you want it to be OPT instead of FLD001. But then you have this line in your program: C Z-ADD 0 OPT 20 You shouldn't define OPT in your program if it's a field from the display file. It's already defined. There are other things, like RRN. It looks like you only use it to decide if *IN30 should be set on. But you could just as easily simply set *IN30 on instead of incrementing RRN. Anyway, without knowing whether this is OPM RPG or it's ILE RPG that's just formatted like old OPM RPG, I can't quite decipher the error. Also, when pasting code, try to select what you pasted and click the {code} button -- that helps preserve the format. Tom
    125,585 pointsBadges:
    report
  • PGMBOB
    Hello. Good find Tom. DDS does not define CF03. Also *in07 is tested but I don't see it defined. The 3010 referenced would indicate the source line with the error. Good luck!
    900 pointsBadges:
    report
  • PGMBOB
    RRN is the subfile record number. Each record written to the subfile needs a new rrn.
    900 pointsBadges:
    report
  • TomLiotta
    3010 referenced would indicate the source line with the error. That's what I thought too, but there's no way for us to match it up. We could think it was sequence # 30.10, so perhaps count down thirty lines to see what's near by. There doesn't seem to be anything obvious above or below for a few lines. And it looks almost as if the error info was copy/pasted into the post. Yet when I look at OPM or ILE RPG listings with 7030 errors, they don't look quite the same -- so it might not be a copy. And if it's not a copy, then it was typed and might have looked like almost anything. Tom
    125,585 pointsBadges:
    report
  • TomLiotta
    Each record written to the subfile needs a new rrn. Sheesh... right. It's been so long since I've looked at that old format that it didn't even click. Tom
    125,585 pointsBadges:
    report
  • Kaly
    [...] AS/400 Subfile Program [...]
    0 pointsBadges:
    report
  • Kaly
    [...] 4. CharlieBrowne, TomLiotta, and PGMBOB help Kaly navigate an AS/400 subfile program. [...]
    0 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following