Hi,
I need to find a string in members of a PDS and want to strip the lines in to spool with program names. I got the expected results using below job but I want to have results with n lines prior and after with specific to search string.
Example:
this is line number 1
this is line number 2
this is line number 3
this is line number 4
this is line number 5
this is line number 6
Expected result.
Srchfor 'line3' with 2 lines prior and after
this is line number 2
this is line number 3
this is line number 4
this is line number 5
this is line number 6
//SRCHFOR JOB (,,time,lines),'your name',CLASS=class
// EXEC PGM=ISRSUPC,
//NEWDD DD DSN=your.data.set.name,DISP=OLD
//OUTDD DD SYSOUT=*
//SYSIN DD *
SRCHFOR 'string1'
/*
Could you please help me to find a option for it.
Thanks
Raja.R
//SRCHFOR JOB (,,time,lines),'your name',CLASS=class
// EXEC PGM=ISRSUPC,
//NEWDD DD DSN=your.data.set.name,DISP=OLD
//OUTDD DD SYSOUT=*
//SYSIN DD *
SRCHFOR 'string1'
/*