IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

how to add a record at the end of a dataset


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Damire

New User


Joined: 25 Aug 2006
Posts: 6

PostPosted: Mon Sep 11, 2006 12:08 pm
Reply with quote

ei guys! just want to ask on how do you indicate that a new record will be added at the last line of a dataset. is der any jcl command that can do this?

tnx in advance!

regards,

dAmire
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2358
Location: Israel

PostPosted: Mon Sep 11, 2006 12:16 pm
Reply with quote

JCL does not have any WRITE commands. However, you can invoke a program using JCL.

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

Active User


Joined: 05 May 2006
Posts: 183
Location: Scotland

PostPosted: Mon Sep 11, 2006 3:05 pm
Reply with quote

Not sure what you are asking here
your topic is how to add a record

try something like this (DISPS at you discretion, assumes all LRECLS etc same)

//S01 EXEC PGM=IEBGENER,COND=(0,NE)
//SYSUT1 DD DSN=MYFILE.ORIGINAL,DISP=SHR
// DD DSN=MYFILE.LAST.LINE,DISP=SHR
//SYSUT2 DD DSN=MYFILE.PLUS.NEW.LAST.LINE,DISP=SHR
//SYSPRINT DD SYSOUT=*
//SYSIN DD DUMMY

but your text asks how to indicate that a record will be written, what do you mean by that?
Back to top
View user's profile Send private message
shyam_shagam

New User


Joined: 07 Sep 2006
Posts: 15
Location: india

PostPosted: Mon Sep 11, 2006 3:35 pm
Reply with quote

dAmire,

By using the following you can do ...........

//REPRO1 EXEC PGM=IDCAMS
//AMSDUMP DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//OLDFILE DD * ( You can give your input dataset here also )
SHYAMSUNDER 1
/*
//NEWFILE DD DSN=Give your existing Dataset to add the recods at end,DISP=MOD
//SYSIN DD *
REPRO INFILE (OLDFILE) OUTFILE (NEWFILE)
//*
*

Thank,
Shyamsunder S [/i][/b]
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
No new posts FINDREP - Only first record from give... DFSORT/ICETOOL 3
No new posts To find whether record count are true... DFSORT/ICETOOL 6
No new posts Map Vols and Problem Dataset All Other Mainframe Topics 2
Search our Forums:

Back to Top