Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Maximum Size of Array

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
Piyari

New User


Joined: 19 Nov 2007
Posts: 4
Location: India

PostPosted: Wed Jan 16, 2008 6:47 pm    Post subject: Maximum Size of Array
Reply with quote

Hi,

I have the below array in one of our copybooks.

05 TBL-CLOTH PIC X(96000).
88 JOB-START VALUE LOW-VALUES, SPACES.

05 TBL-LINER REDEFINES TBL-CLOTH.
10 CS-TAB OCCURS 8000.
15 CPGN PIC X(06).
15 SRCC PIC X(06).

...and i have a requirement to change the size of CS-TAB to the maximum size cobol allows...

Could you pls assist?

Our installation uses VS COBOL II... FYI.

Thanks.
Back to top
View user's profile Send private message

Phrzby Phil

Active Member


Joined: 31 Oct 2006
Posts: 965
Location: Richmond, Virginia

PostPosted: Wed Jan 16, 2008 6:51 pm    Post subject:
Reply with quote

Why not just try various values till you hit the max?

A binary search is most efficient. Try a huge number that will fail, then try half of that. If it works, try halfway up to your 1st try; if not, try halfway down. Now iterate the previous sentence.

This should take you maybe 30 minutes, rather than the several days you'll wait for an (either wrong or installation specific (and you won't even know which, if either)) answer you'll get here.

Let us know the answer please.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4650
Location: Raleigh, NC, USA

PostPosted: Wed Jan 16, 2008 6:52 pm    Post subject: Reply to: Maximum Size of Array
Reply with quote

Here's a link to the documented specifications for limits.
Back to top
View user's profile Send private message
TG Murphy

Active User


Joined: 23 Mar 2007
Posts: 149
Location: Ottawa Canada

PostPosted: Wed Jan 16, 2008 8:48 pm    Post subject:
Reply with quote

You are asking for the biggest possible OCCURS. You really should figure out how much you need instead of asking for the biggest possible number.

If you don't know this number - then how do you know that this number will be less than what is possible? Maybe the use of a table is no longer appropriate because your volumes have grown too big. Maybe you need to store your data in a database instead of a table.

I think you should first figure out how big you need your OCCURS to be. And then figure out whether COBOL and your system can accommodate this. As well, if your program will run under CICS grabbing all the storage that you can possibly grab will surely result in the CICS performance guys paying you a nasty visit.
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Wed Jan 16, 2008 11:01 pm    Post subject:
Reply with quote

Hello,

Quote:
and i have a requirement to change the size of CS-TAB to the maximum size cobol allows
A very poor alternative. . . .

This is most likely an extreme waste of resources and if the volume is growing, it will most likely "blow up" one day when it can be least afforded.

Better to implement a solution that uses less resources and will work even with higher volume.
Back to top
View user's profile Send private message
Piyari

New User


Joined: 19 Nov 2007
Posts: 4
Location: India

PostPosted: Thu Jan 17, 2008 11:07 am    Post subject:
Reply with quote

Hi Kevin,

Thanks for the link. This is exactly what i was looking for.

Phil,

Why reinvent the wheel - especially if its just a spec that comes in a manual?

Murphy & Dick,

I am well aware of the storage and performance implications on doing this change, even before i posted this question here.

My customer is stubborn on this change for some reason. I got to prove him wrong....May be with a pinch of strobe and Omegamon stats in test region icon_wink.gif

Anyway thank you all for your time!
Back to top
View user's profile Send private message
Phrzby Phil

Active Member


Joined: 31 Oct 2006
Posts: 965
Location: Richmond, Virginia

PostPosted: Thu Jan 17, 2008 6:20 pm    Post subject:
Reply with quote

Specs change, manuals get old. If you want to really know for sure, you cannot rely on everything you read.
Back to top
View user's profile Send private message
stodolas

Active Member


Joined: 13 Jun 2007
Posts: 632
Location: Wisconsin

PostPosted: Thu Jan 17, 2008 6:21 pm    Post subject:
Reply with quote

Our TECH support for the mainframe would kill this app everytime it ran for being a memory hog. I had one app I was trying to write for maximum flexibility and they said if I put it into production they would disable it because it used too much memory. Using that much memory killed the CICS region I was testing in.
Back to top
View user's profile Send private message
TG Murphy

Active User


Joined: 23 Mar 2007
Posts: 149
Location: Ottawa Canada

PostPosted: Mon Jan 21, 2008 8:07 pm    Post subject:
Reply with quote

Piyari,

Very important for to know whether you need to run your program under CICS or batch. If batch only, then I would suggest you just experiment to see what works at your shop.

Last time I checked we had a batch program that defined a table that was 30,000,000 bytes long. So I checked again and this time I found a program that had several 20,000,000 byte tables and this program's total working storage was 76,000,000 bytes. This is huge and is not typical.

Keep in mind - the group that owns these programs was very careful in getting approval to do this. Just to the same so that your ass is covered.

Good luck..
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts How to write Rexx program to size and... sreejeshcs CLIST & REXX 14 Thu Oct 12, 2017 7:26 am
No new posts JES2 job size field matching Windows ... SRICOBSAS All Other Mainframe Topics 4 Tue Sep 05, 2017 5:49 pm
No new posts To find out size allocated to a seque... ashek15 JCL & VSAM 15 Thu Apr 27, 2017 9:42 am
No new posts Dynamic array request/response contai... Suja.Sai CICS 2 Tue Jan 24, 2017 11:37 am
No new posts Increase the screen size after split mistah kurtz TSO/ISPF 2 Fri Sep 02, 2016 6:39 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us