how to read contents of ksds



JES, JES2, JCL utilities, IDCAMS, Compile & Run JCLs, PROCs etc...

how to read contents of ksds

Postby nagendra » Tue Jul 20, 2010 11:34 am

how to view contents of a ksds file.
Nagendra
nagendra
 
Posts: 21
Joined: Mon Jul 19, 2010 12:18 pm
Location: bangalore
Has thanked: 0 time
Been thanked: 0 time

Re: how to read contents of ksds

 

Re: how to read contents of ksds

Postby smita257 » Tue Jul 20, 2010 11:57 am

If you want to read the KSDS, do you want to read it sequentially or randomly?
If sequential then perform a startbrowse in your program checking the key value and then read.
If random directly move the value into key and read the file.
smita257
 
Posts: 13
Joined: Mon Jul 19, 2010 2:39 pm
Has thanked: 0 time
Been thanked: 0 time

Re: how to read contents of ksds

Postby smita257 » Tue Jul 20, 2010 12:37 pm

You can also view by print the contents through IDCAMS.
//PRINT EXEC PGM=IDCAMS
//SYSPRINT  DD SYSOUT=*
//INPUT DD DSN=YOUR.KSDS,DISP=OLD
//SYSIN DD *
 PRINT
 INFILE(INPUT)
/*
smita257
 
Posts: 13
Joined: Mon Jul 19, 2010 2:39 pm
Has thanked: 0 time
Been thanked: 0 time

Re: how to read contents of ksds

Postby nagendra » Tue Jul 20, 2010 2:29 pm

smita257 wrote:U can also view by print the contents through IDCAMS.
//PRINT EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//INPUT DD DSN=YOUR.KSDS,DISP=OLD
//SYSIN DD *
PRINT
INFILE(INPUT)
/*



thanx a lot...
Nagendra
nagendra
 
Posts: 21
Joined: Mon Jul 19, 2010 12:18 pm
Location: bangalore
Has thanked: 0 time
Been thanked: 0 time

Re: how to read contents of ksds

Postby NicC » Tue Jul 20, 2010 7:29 pm

//INPUT DD DSN=YOUR.KSDS,DISP=OLD


I would change the DISP to SHR unless you have a real need to have exclusve use of the dataset
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 2690
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisys (almost)
Has thanked: 4 times
Been thanked: 105 times

Re: how to read contents of ksds

Postby smita257 » Wed Jul 21, 2010 10:32 am

Yes.That's correct.
smita257
 
Posts: 13
Joined: Mon Jul 19, 2010 2:39 pm
Has thanked: 0 time
Been thanked: 0 time

Re: how to read contents of ksds

Postby nagendra » Wed Jul 21, 2010 1:50 pm

smita257 wrote:You can also view by print the contents through IDCAMS.
//PRINT EXEC PGM=IDCAMS
//SYSPRINT  DD SYSOUT=*
//INPUT DD DSN=YOUR.KSDS,DISP=OLD
//SYSIN DD *
 PRINT
 INFILE(INPUT)
/*



yaa, i just testd it, i got the concept... thanx a lot..
Nagendra
nagendra
 
Posts: 21
Joined: Mon Jul 19, 2010 12:18 pm
Location: bangalore
Has thanked: 0 time
Been thanked: 0 time


Return to JCL

 


  • Related topics
    Replies
    Views
    Last post