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 

Need some idea regdJCL

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Job Control Language(JCL)
View previous topic :: View next topic  
Author Message
aquarian
Beginner


Joined: 28 Sep 2005
Posts: 66
Topics: 17
Location: Mars

PostPosted: Wed Sep 20, 2006 1:24 am    Post subject: Need some idea regdJCL Reply with quote

I have a file with 100 records
Give me some idea to write a JCL that reads the file and writes each record to different file ....


Thank you
_________________
cheers,
Aquarian
Back to top
View user's profile Send private message Send e-mail Visit poster's website MSN Messenger
ofer71
Intermediate


Joined: 12 Feb 2003
Posts: 358
Topics: 4
Location: Israel

PostPosted: Wed Sep 20, 2006 2:49 am    Post subject: Reply with quote

1. COBOL program
2. REXX exec
3. Edit-Macro
4. SORT utility
etc...

O.
________
medical marijuana dispensary


Last edited by ofer71 on Sat Feb 05, 2011 11:49 am; edited 1 time in total
Back to top
View user's profile Send private message Send e-mail
shekar123
Advanced


Joined: 22 Jul 2005
Posts: 528
Topics: 90
Location: Bangalore India

PostPosted: Wed Sep 20, 2006 4:52 am    Post subject: Reply with quote

aquarian,

Here are the solutions: for COBOL and SORT

COBOL:
Code:

//STEP010 EXEC PGM=YOUR PROGRAM NAME,
//STEPLIB DD   DSN=YOUR LOAD PDS,DISP=SHR
//IN      DD   DSN=YOUR INPUT DATASET NAME WHICH HAS 100 RECORDS IN IT,DISP=SHR
//OUT     DD   DSN=OUTPUT NEW DATASET IN WHICH WE WILL WRITE THE 100 RECORDS INTO IT,
//             DISP=(NEW,CATLG,DELETE),
//             SPACE=(TRK,(1,1),RLSE),UNIT=SYSDA,
//             DCB=(LRECL=80,RECFM=FB,BLKSIZE=800)

DFSORT
Code:

//STEP010 EXEC PGM=SORT
//SORTIN  DD   DSN=YOUR NPUT DATASET WHICH HAS 100 RECORDS,DISP=SHR
//SORTOUT DD   DSN=OUTPUT NEW DATASET WHICH WILL GET THE 100 RECORDS COPIED INTO IT,
//             DISP=(NEW,CATLG,DELETE),
//             SPACE=(TRK,(1,1),RLSE),UNIT=SYSDA,
//             DCB=(LRECL=80,RECFM=FB,BLKSIZE=800)
//*YOU CAN USE SORT FIELDS=COPY OR OPTION COPY
//SYSIN   DD *
  SORT FIELDS=COPY
/*
//

_________________
Shekar
Grow Technically
Back to top
View user's profile Send private message
acevedo
Beginner


Joined: 03 Dec 2002
Posts: 127
Topics: 0
Location: Europe

PostPosted: Wed Sep 20, 2006 5:16 am    Post subject: Re: Need some idea regdJCL Reply with quote

with

aquarian wrote:
...and writes each record to different file ....


do you mean one different ouput file for every input record?
1 input file with 3 records => 3 files with 1 record each one. ???
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 -> Job Control Language(JCL) 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