MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

occurs clause with fillers

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming
View previous topic :: View next topic  
Author Message
suma
Beginner


Joined: 23 Jan 2006
Posts: 65
Topics: 29

PostPosted: Wed Jan 16, 2008 8:45 am    Post subject: occurs clause with fillers Reply with quote

Hi all,

Does anyone know; what how these fillers are related to TABLE-RECORD table..please let me know.
Code:

01  FILLER   PIC X(29) VALUE 'RECORD HOLD TABLE STARTS HERE'.
01  RECORD-HOLD-TABLE.                                 
    05  TABLE-RECORD                 OCCURS 728 TIMES. 
        10  FILLER                  PIC X(161).         
        10  TABLE-CLAIM-INFO-RBA    PIC X(04).         
        10  FILLER                  PIC X(15).         
01  FILLER                          PIC X(30000).       
01  FILLER                          PIC X(30000).       
01  FILLER                          PIC X(30000).       
01  FILLER                          PIC X(30000).       
01  FILLER                          PIC X(30000).       
01  FILLER                          PIC X(30000).       
01  FILLER                          PIC X(30000).       
01  FILLER                          PIC X(30000).       
01  FILLER                          PIC X(30000).               
01  END-OF-TBL-REC1       PIC X(19) VALUE 'END OF TABLE RECORD'.


Thanks
Suma
Back to top
View user's profile Send private message
CraigG
Intermediate


Joined: 02 May 2007
Posts: 202
Topics: 0
Location: Viginia, USA

PostPosted: Wed Jan 16, 2008 9:23 am    Post subject: Reply with quote

Looks like someone is trying to reserve extra space for the table-record table. It is not a save way to do it, if subscript range checking is in on then the extra occurances can't be accessed and if the compilier optimizer is used the space won't be there. Poor programming and poor documentation causes many problems.
Back to top
View user's profile Send private message
suma
Beginner


Joined: 23 Jan 2006
Posts: 65
Topics: 29

PostPosted: Wed Jan 16, 2008 9:39 am    Post subject: Reply with quote

Thanks CraigG for your quick reply....

Is there any way I can change this type of coding..!
We are getting S0C4 abend due to this array from long back..and we are keep on adding more and more fillers to this array.



regards
Suma
Back to top
View user's profile Send private message
jsharon1248
Intermediate


Joined: 08 Aug 2007
Posts: 291
Topics: 2
Location: Chicago

PostPosted: Wed Jan 16, 2008 9:54 am    Post subject: Reply with quote

Is this a really old program? Also, is the code referencing occurrences in the table higher than 728? I remember the old COBOL table size limits were much lower than they are now, although I can't find a manual old enough to say what the old limits were. The new table size limit is about 16MB, so if you have a chance to eliminate the intentional table overflow, I'd say, do it.
Back to top
View user's profile Send private message
suma
Beginner


Joined: 23 Jan 2006
Posts: 65
Topics: 29

PostPosted: Wed Jan 16, 2008 10:07 am    Post subject: Reply with quote

yes..this is one of the old program in our shop. This program was created in 1994 and using old compiler. I cann't able to change the occurs clause. when I tried to change the occurs clause I got the error as shown...

"FIXED LENGTH GROUP ITEM IN WORKING-STORAGE OR LINKAGE SECTION IS GT 131,071 BYTES.
TRUNCATED TO 131,071. "

I think there is no way without adding the extra fillers...


Thanks
Suma
Back to top
View user's profile Send private message
CraigG
Intermediate


Joined: 02 May 2007
Posts: 202
Topics: 0
Location: Viginia, USA

PostPosted: Wed Jan 16, 2008 10:16 am    Post subject: Reply with quote

suma wrote:
Thanks CraigG for your quick reply....

Is there any way I can change this type of coding..!
We are getting S0C4 abend due to this array from long back..and we are keep on adding more and more fillers to this array.



regards
Suma


Switch to a newer compiler. Other then that you would have to rewrite the program to change what is being saved in the table or switch to a different type of logic.
Back to top
View user's profile Send private message
jsharon1248
Intermediate


Joined: 08 Aug 2007
Posts: 291
Topics: 2
Location: Chicago

PostPosted: Wed Jan 16, 2008 2:10 pm    Post subject: Reply with quote

You could modify the process to utilize a VSAM file. If you have a unique key, you could use a KSDS file. If it's not unique, you could define an alternate index and utilize that. You could also try an RRDS file. Any of these options eliminates your worries about table overflow. I'd recommend creating the VSAM file in a separate step and reading it in the program that you posted. You could load and process in the same pgm, but it would probably be cleaner to separate the tasks.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group