View previous topic :: View next topic
|
Author |
Message |
Suryyogi
New User
Joined: 17 Jun 2006 Posts: 27
|
|
|
|
can anybody tell me plz
how to specify FD entry for file which is variable blocked
plz give example.
i have a file having record length 80 record format VB and blocksize 800
.
regards
yogesh |
|
Back to top |
|
|
DavidatK
Active Member
Joined: 22 Nov 2005 Posts: 700 Location: Troy, Michigan USA
|
|
|
|
Reading/Writing variable records has been discussed many times. Do a search and if your question is not answered, please come back.
Dave |
|
Back to top |
|
|
shrinivas_3 Warnings : 1 New User
Joined: 05 Sep 2006 Posts: 34
|
|
|
|
Suryyogi wrote: |
can anybody tell me plz
how to specify FD entry for file which is variable blocked
plz give example.
i have a file having record length 80 record format VB and blocksize 800
.
regards
yogesh |
Hi
here is one example :
here we use 4 layout to see the content of one VB file
FD ERD-FILE
RECORDING MODE IS V
RECORD CONTAINS 42 TO 205 CHARACTERS
BLOCK CONTAINS 0 RECORDS
LABEL RECORD ARE STANDARD
DATA RECORDS ARE P-MER-INFO-REC
P-OR-DETL-INFO
P-ORT-SE-INFO
P-ORTR-OBE-INFO.
++INCLUDE AAAA (FOR P-MER-INFO-REC -> LRECL= 83)
++INCLUDE BBBB (FOR P-OR-DETL-INFO -> LRECL= 205)
++INCLUDE CCCC (FOR P-ORT-SE-INFO -> LRECL= 59 )
++INCLUDE DDDD (FOR P-ORTR-OBE-INFO -> LRECL= 42)
NOTE THAT HERE WE HAD USED INCLUDES FOR FILE LAYOUT.
ALSO IN JCL YOU NEED TO DEFINE LRECL 4 BYTES MORE THAN MAX LRECL .(block size does not has any effect)
EG :
FILE DD DSN=FILE NAME ,
DISP=(NEW,CATLG,DELETE),
SPACE=(CYL,(100,50),RLSE),UNIT=SYSDA,
DCB=(LRECL=209,RECFM=VB,BLKSIZE=0)
HOPE this clears your doubt.
thanks |
|
Back to top |
|
|
sudhakar_mainframe Warnings : 1 New User
Joined: 29 Jun 2006 Posts: 25
|
|
|
|
Hi shrinivas_3,
I have one small doubt about Logical record length.Why we are
giving it as (Size + 4) bytes in DCB.
Thanks,
Sudhakar |
|
Back to top |
|
|
shrinivas_3 Warnings : 1 New User
Joined: 05 Sep 2006 Posts: 34
|
|
|
|
sudhakar_mainframe wrote: |
Hi shrinivas_3,
I have one small doubt about Logical record length.Why we are
giving it as (Size + 4) bytes in DCB.
Thanks,
Sudhakar |
Hi
whenever we deal with variable length file , we need to give 4bytes extra. Variable-length records are prefixed and suffixed by 4 bytes of control information containing length fields. The 4-byte integer value stored in each length field indicates the number of data bytes (excluding overhead bytes) in that particular variable-length record.
try out below link for more information:
www.simotime.com/cblv8001.htm
thanks |
|
Back to top |
|
|
|