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
 

 

Variable record length ( In JCL)

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

New User


Joined: 06 Mar 2006
Posts: 50
Location: PUNE

PostPosted: Tue Jun 20, 2006 11:36 am    Post subject: Variable record length ( In JCL)
Reply with quote

Hi All,

Can any one tell me about how to specify DCB parameters for variable record length?

Input file is of VB
Output file is to be created with FB recfm.

I will more greatful if anybody send more information about this topic.

plese do reply..

Regards
Anand
Back to top
View user's profile Send private message

Prasanthhere

Active User


Joined: 03 Aug 2005
Posts: 306

PostPosted: Tue Jun 20, 2006 2:09 pm    Post subject: Re: Variable record length ( In JCL)
Reply with quote

For variable record length the DCB parametere can be

RECFM=V
LRECL is the logical record length
BLKSIZE equals LRECL plus 4.
Back to top
View user's profile Send private message
shekhar1s

New User


Joined: 13 Apr 2006
Posts: 14
Location: USA

PostPosted: Tue Jun 20, 2006 2:44 pm    Post subject: Re:Variable record length ( In JCL)
Reply with quote

DCB For Variable length record....
DCB=(DSORG=PS,LRECL=80,RECFM=VB,BLKSIZE=800)
Block size should be in multiples of record length. And as per my knowledge.. it automatically takes the four bytes when we declare the record format as VB(variable length).

And About output file... u can create it in the JCL itself or using 3.2 option..

please let me know if i'm wrong....
Thanks
Shekhar
Back to top
View user's profile Send private message
Rupesh.Kothari

Member of the Month


Joined: 27 Apr 2005
Posts: 464

PostPosted: Tue Jun 20, 2006 7:11 pm    Post subject: Re: Variable record length ( In JCL)
Reply with quote

Hi Anand,

Quote:
Hi All,

Can any one tell me about how to specify DCB parameters for variable record length?

Input file is of VB
Output file is to be created with FB recfm.

I will more greatful if anybody send more information about this topic.

plese do reply..

Regards
Anand


As per your query, ur Input is VB then u can mention in JCL as SHR and no need to mention DCB parameter.

Hope this helps

Regards
Rupesh
Back to top
View user's profile Send private message
Husna

New User


Joined: 02 Jun 2006
Posts: 49

PostPosted: Wed Jun 21, 2006 10:06 am    Post subject:
Reply with quote

Hi,

Will you please let me know about the four bytes when we declare the record format as VB(variable length). It will store the variable length at the begining of the first four bytes or end of the last four bytes.
Back to top
View user's profile Send private message
guptae

Moderator


Joined: 14 Oct 2005
Posts: 1187
Location: Bangalore,India

PostPosted: Wed Jun 21, 2006 12:02 pm    Post subject:
Reply with quote

It will store the length in first 4 bytes
Back to top
View user's profile Send private message
sathish_seabiscuit

New User


Joined: 14 Jun 2006
Posts: 4

PostPosted: Wed Jun 21, 2006 5:52 pm    Post subject: Re: Variable record length ( In JCL)
Reply with quote

We can use ICEGENER utility.

In the code,
RIS&ENV..P370.UNLOAD.RECIPTSI.BSAM - Variable length file
RIS&ENV..P370.RECIPTSI.BSAM -Fixed length file
RISL3701 is given at last.

//ICEGEN01 EXEC PGM=ICEGENER,COND=(04,LT)
//*
//SYSUT1 DD
DSN=RIS&ENV..P370.UNLOAD.RECIPTSI.BSAM,
// DISP=SHR
//SYSUT2 DD DSN=RIS&ENV..P370.RECIPTSI.BSAM,
// DISP=(NEW,CATLG,DELETE),
// DCB=(RECFM=FB,LRECL=173),
// SPACE=(173,&SPMED.,RLSE),
// UNIT=&UNITWRK
//SYSIN DD DSN=&QUAL..PARMLIB(RISL3701),
// DISP=SHR
//SORTMSG DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=Z
//*

Parm RISL3701,

GENERATE MAXFLDS=1
RECORD FIELD=(173,1)
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Wed Jun 21, 2006 8:32 pm    Post subject:
Reply with quote

Quote:
Will you please let me know about the four bytes when we declare the record format as VB(variable length). It will store the variable length at the begining of the first four bytes or end of the last four bytes.


The first four bytes of every VB record is the Record Descriptor Word (RDW). The first two bytes of the RDW contain the record length in binary usually followed by two bytes of binary zeros. For example, an 80-byte VB record will have an RDW of X'00500000'.
Back to top
View user's profile Send private message
Bharanidharan

New User


Joined: 20 Jun 2005
Posts: 86
Location: Chennai, India

PostPosted: Thu Jun 22, 2006 12:33 pm    Post subject: Re: Variable record length ( In JCL)
Reply with quote

Frank,
This one has always nagged me - what are the 2 bytes of binary zeros used for? I've always been told "It is for IBM purposes"! Could you explain?
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Thu Jun 22, 2006 8:46 pm    Post subject:
Reply with quote

For a VB file the two bytes are not used for anything. But for a variable spanned (VBS, VS) file, the first four bytes are an SDW (segment descriptor word) rather than an RDW. In the SDW, the first two bytes are the length in binary, but the third byte contains the segment control code (first, middle, last). For more information on the SDW, see:

http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/dgt2d440/3.1.3.2.2?SHELF=EZ2ZO10G&DT=20050602124524&CASE=
Back to top
View user's profile Send private message
puneet478

New User


Joined: 03 Jan 2006
Posts: 13
Location: Bangalore india

PostPosted: Fri Jun 23, 2006 4:43 am    Post subject: Re: Variable record length ( In JCL)
Reply with quote

Hi,

The DCB will look like as follows:

//M57Tst DD DSN=input.data.set,
// DISP=(NEW,CATLG,DELETE),
// UNIT=TSODA,DATACLAS=STANDARD,
// DCB=(RECFM=VB,LRECL=704,BLKSIZE=0),
// EXPDT=2007/350

You can change the LRECL and EXPDT fields.

Hope this will help.

- Puneet
Back to top
View user's profile Send private message
cjcpr

New User


Joined: 21 Mar 2006
Posts: 21
Location: USA

PostPosted: Fri Jul 07, 2006 10:56 pm    Post subject:
Reply with quote

simple solutio n is using a OUTREC field with CONVERT parameter.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Fri Jul 07, 2006 11:32 pm    Post subject:
Reply with quote

See the following Smart DFSORT Trick for converting VB to FB:

http://www.ibm.com/servers/storage/support/software/sort/mvs/tricks/srtmst01.html#t11

See the following Smart DFSORT Trick for converting FB to VB:

http://www.ibm.com/servers/storage/support/software/sort/mvs/tricks/srtmst03.html#t09
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 Converting Variable block file to Fix... bhavana yalavarthi DFSORT/ICETOOL 10 Tue May 16, 2017 2:20 pm
No new posts Adding big TEXT lines to each record ... bshkris SYNCSORT 4 Sat May 06, 2017 1:40 am
No new posts Getting error while opening a variabl... apandey1 COBOL Programming 5 Fri May 05, 2017 12:22 pm
This topic is locked: you cannot edit posts or make replies. Merge two files and update Trailer re... Yashashri JCL & VSAM 1 Thu May 04, 2017 12:54 pm
No new posts Length of Tape file Mohan Kothakota JCL & VSAM 9 Thu Apr 20, 2017 10:24 pm


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