Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

the use of AVGREC parameter.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
mf_user
Currently Banned

New User


Joined: 05 Jan 2006
Posts: 47

PostPosted: Fri Jan 13, 2006 11:54 am    Post subject: the use of AVGREC parameter.
Reply with quote

Hi,

I have created a new OUTPUT dataset in the following way:

//SYSUT1 DD DSN=INPUT.DATASET.IP,
// DISP=(NEW,CATLG,CATLG),
// SPACE=(1048,(10,5),RLSE),
// VOL=(,,,5),
// UNIT=PERMDA,
// AVGREC=K,
// RECFM=FB,
// LRECL=1048,
// BLKSIZE=27248
//*

Due to huge incoming data the job abended with SB37. So, the programmer did the following change and reran the job successfully.

//SYSUT1 DD DSN=INPUT.DATASET.IP,
// DISP=(NEW,CATLG,CATLG),
// SPACE=(1500,(10,5),RLSE),
// VOL=(,,,5),
// UNIT=PERMDA,
// AVGREC=K,
// RECFM=FB,
// LRECL=1048,
// BLKSIZE=27248
//*

After completion of the job, the dataset was created with the LRECL of 1048 only. I would like to know how it could be possible even though the SPACE param was changed to have a AVGREC of 1500. (1048 value was changed to 1500 !!!!)

Your inputs are most welcome to make this understand.

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

Gautam512

Active User


Joined: 05 Oct 2005
Posts: 309
Location: Vizag / US

PostPosted: Fri Jan 13, 2006 12:30 pm    Post subject: Re: the use of AVGREC parameter.
Reply with quote

HI,

Space parameters are no way related to the LRECL.

SPACE parameter requests space for a new data set on a DASD
volume. You can either request an amount of space and let MVS
locate the space for you, or you can request specific track numbers
on a DASD volume.

The LRECL parameter is used to specify the logical record length for the records in a data set. Its function is equivalent to that of the LRECL= subparameter of the DCB=parameter.
LRECL can be used to override the LRECL information for a data class
if SMS (System Managed Storage) is installed and active.

Thanks,
Gau
Back to top
View user's profile Send private message
gowtham_1982
Warnings : 1

Active User


Joined: 02 Dec 2005
Posts: 109

PostPosted: Fri Jan 13, 2006 3:33 pm    Post subject: Re: the use of AVGREC parameter.
Reply with quote

Gautam512 wrote:
HI,

Space parameters are no way related to the LRECL.

SPACE parameter requests space for a new data set on a DASD
volume. You can either request an amount of space and let MVS
locate the space for you, or you can request specific track numbers
on a DASD volume.

The LRECL parameter is used to specify the logical record length for the records in a data set. Its function is equivalent to that of the LRECL= subparameter of the DCB=parameter.
LRECL can be used to override the LRECL information for a data class
if SMS (System Managed Storage) is installed and active.

Thanks,
Gau


hai mf_user,

what Gau said is right.

corrections welcomed...

gowtham
Back to top
View user's profile Send private message
mf_user
Currently Banned

New User


Joined: 05 Jan 2006
Posts: 47

PostPosted: Fri Jan 13, 2006 6:57 pm    Post subject: space like this
Reply with quote

So, instead of giving the

SPACE=(LRECL,(M,N),RLSE),
AVGREC=K,
LRECL=250

I can also give as mentioned here

SPACE=(TRKS,(M,N),RLSE),
AVGREC=K,
LRECL=250

Please enlighten me.
Back to top
View user's profile Send private message
Gautam512

Active User


Joined: 05 Oct 2005
Posts: 309
Location: Vizag / US

PostPosted: Fri Jan 13, 2006 8:08 pm    Post subject: Re: the use of AVGREC parameter.
Reply with quote

Hi mf_user,

Go thru the attachemetn ,u'll have gud idea of space parameter.....

Thanks,
Gau
Back to top
View user's profile Send private message
mf_user
Currently Banned

New User


Joined: 05 Jan 2006
Posts: 47

PostPosted: Sat Jan 14, 2006 4:02 pm    Post subject: thanks.
Reply with quote

Thanks for the doco.
Back to top
View user's profile Send private message
Gautam512

Active User


Joined: 05 Oct 2005
Posts: 309
Location: Vizag / US

PostPosted: Tue Jan 17, 2006 6:24 pm    Post subject: Re: the use of AVGREC parameter.
Reply with quote

Ur most welcome .........

Thanks,
Gau
Back to top
View user's profile Send private message
priya

Moderator


Joined: 24 Jul 2003
Posts: 568
Location: Bangalore

PostPosted: Sat Feb 16, 2008 3:25 am    Post subject:
Reply with quote

Quote:
So, instead of giving the

SPACE=(LRECL,(M,N),RLSE),
AVGREC=K,
LRECL=250

I can also give as mentioned here

SPACE=(TRKS,(M,N),RLSE),
AVGREC=K,
LRECL=250

Please enlighten me.


No, You can't. AVGREC parameter cannot be specified when TRK/CYL is used in the SPACE Parameter. (And its TRK, not TRKS)
Back to top
View user's profile Send private message
leo_sangha

New User


Joined: 11 Aug 2005
Posts: 85
Location: England

PostPosted: Wed Apr 02, 2008 7:44 pm    Post subject: Reply to: the use of AVGREC parameter.
Reply with quote

Quote:
No, You can't. AVGREC parameter cannot be specified when TRK/CYL is used in the SPACE Parameter. (And its TRK, not TRKS)


Hi Priya,

I also read it in the Manual that AVGREC parameter should not be coded with TRK/CYL parameters. BUT STILL

I am just curious to know what will happen if i give space parameters as shown below:

LRECL=800,
SPACE=(CYL,(3000,1000),RLSE),AVGREC=K

Can you please clarify if what i am thinking is correct:

For the above space allocation:

The MVS will try to allocate 3000 X 1024 cylinders every time.

OR
It will ignore the CYL part and will try to allocate
800 X 1024 bytes of Primary Quantity.

Please share your views on this.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Wed Apr 02, 2008 7:47 pm    Post subject:
Reply with quote

Well, however you decide to allocate your DASD space, the operating system always converts in into either tracks or cylinders, which are the only two values accepable by the DASD subsystems.

It's not difficult to work out space requirements, so why not just stick to TRK & CYL
Back to top
View user's profile Send private message
leo_sangha

New User


Joined: 11 Aug 2005
Posts: 85
Location: England

PostPosted: Wed Apr 02, 2008 11:37 pm    Post subject: Reply to: the use of AVGREC parameter.
Reply with quote

Thanks for the prompt reply.

But still i would like to know what will happen if i code the space parameters like :

I know that if i code:
LRECL=100,
SPACE=(100,(50,10),RLSE),AVGREC=K

MVS will allocate space equivalent to (50 X 1024 records) of LRECL 100.

what will happen if i code

LRECL=100,
SPACE=(CYL,(50,10),RLSE),AVGREC=K

how will MVS allocate space ? Thanks !
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10211
Location: italy

PostPosted: Wed Apr 02, 2008 11:47 pm    Post subject: Reply to: the use of AVGREC parameter.
Reply with quote

The manual is clear icon_cool.gif

Quote:
12.5 AVGREC Parameter
Parameter Type Keyword, optional -- use this parameter only with SMS
Purpose Use the AVGREC parameter when you define a new data set to specify that:
* The units of allocation requested for storage space are records.
* The primary and secondary space quantity specified on the SPACE parameter represents units, thousands, or millions of records.
When you use AVGREC with the SPACE parameter, the first subparameter (reclgth) on the SPACE parameter must specify the average record length of the records.
Code the AVGREC parameter when you want to (1) specify records as the units of allocation or (2) override the space allocation defined in the data class for the data set.
If SMS is not installed or is not active, the system checks the syntax and then otherwise ignores the AVGREC parameter.
Back to top
View user's profile Send private message
leo_sangha

New User


Joined: 11 Aug 2005
Posts: 85
Location: England

PostPosted: Thu Apr 03, 2008 6:56 pm    Post subject: Reply to: the use of AVGREC parameter.
Reply with quote

Thanks Enrico, it was really helpful.

I am left to assume in production either SMS is not installed or NOT active, otherwise the job should have abended(Reason - Syntax Error), for coding space parameters as below :

SPACE=(CYL,(50,10),RLSE),AVGREC=K

And the AVGREC parameter is getting ignored all the times.

Am i on the right track now icon_question.gif
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10211
Location: italy

PostPosted: Thu Apr 03, 2008 7:02 pm    Post subject: Reply to: the use of AVGREC parameter.
Reply with quote

almost icon_smile.gif

as the docs says avgrec is ignored when the allocation unit does not represent a record length ( not numeric )
Back to top
View user's profile Send private message
vamskrish
Warnings : 1

New User


Joined: 31 Jan 2007
Posts: 27
Location: virginia

PostPosted: Tue Apr 29, 2008 6:23 am    Post subject:
Reply with quote

AVGREC=U - means 100's of records
AVGREC=K - means 1000's of records
AVGREC=M - means millions of records

when u use AVGREC parameter, u dont use CYL OR TRKS in ur space parm. instead u use the record length of the file.

for ex:

SPACE=(100,(10,5),RLSE),AVGREC=K means that ur output file can handle
primary space for 10 * 1000 = 10,000 records each of length 100. this is the best practice to avoid using CYL and TRKS.

similarly
SPACE=(100,(10,5),RLSE),AVGREC=M, means ur output file can handle 10 million records.

if u know approx., how many records ur output file will have then u can use AVGREC. if there are million records and if u have mentioned
AVGREC = K, then u will get space abend.
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts DDNAME parameter mistah kurtz JCL & VSAM 6 Mon Dec 19, 2016 4:41 pm
No new posts Execessive parameter issue Sumeendar JCL & VSAM 5 Mon Dec 19, 2016 4:35 pm
No new posts TOT & DATE parameter in ICEMAN hemanthj642 DFSORT/ICETOOL 4 Mon Nov 14, 2016 5:19 am
No new posts How to display value of an exit param... lind sh CICS 2 Sun Oct 09, 2016 12:28 pm
No new posts Send parameter for macro STIMERM from... Daniel Teolotitla PL/I & Assembler 13 Tue Jul 05, 2016 9:23 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us