How do u debug a S0C7 abend? (aswered till we get the field
which caused that)
After knowing the field which caused that how do u know the
record which caused that if it is in production env? (dumb)
Ok let us assume that we got to know that 100th record
caused that and I wanted to skip only 100th record from the
file and process from 101th.
How to do that in JCL using SORT? (tried with STOPAFT
but ended up dumb when he said smthing else is ther)

Answers were Sorted based on User's Feedback



How do u debug a S0C7 abend? (aswered till we get the field which caused that) After knowing the ..

Answer / sandeep negi

If you came to know which field is responsible for that.
you can run your testjcl with output file DISP parameter as
(NEW,CATLG,CATLG), by doing so, your output file will get
created irrespective of SOC7 abend becuase the last record
of your outuput file will be responsible for generating
abend.

Now you can strip off that record (because its bad data)
and run your jcl.

How to Skip any record through JCL -
You can use ICETOOL

//S1 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN DD DSN=... input file
//OUT DD DSN=... output file
//TOOLIN DD *
SUBSET FROM(IN) TO(OUT) REMOVE INPUT RRN(100)

this will remove 100th record from your file and will copy
rest all records into ouptput file.

Is This Answer Correct ?    3 Yes 0 No

How do u debug a S0C7 abend? (aswered till we get the field which caused that) After knowing the ..

Answer / hks

Use OMIT option of Sort Utillity

Is This Answer Correct ?    2 Yes 0 No

How do u debug a S0C7 abend? (aswered till we get the field which caused that) After knowing the ..

Answer / varun

You need to you SKIPREC and not STOPAFT here.

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More COBOL Interview Questions

what is the difference between PA & PF keys?

1 Answers   IBM,


What was removed from COBOL in the COBOL II implementation?

0 Answers  


What is the difference between comp and comp-3?

0 Answers  


01 MOVE 10 TO N 05 PERFOM PARA1 TIMES STOP RUN WAT WILL HAPPEN?? WILL IT RUN INFINITELY OR AN ERROR WIL BE THER BECAUSE NO OF TIMES IS NOT GIVEN??

1 Answers  


In EBCDIC, how would the number 1234 be stored?

2 Answers   TCS,






how will u find out 3rd week's 2nd day using occurs ?

3 Answers   L&T,


consider the following piece of code 01 GROSS-PAY 05 BASIC-PAY PIC 9(5) 05 ALLOWENCES PIC 9(3) if BASIC-PAY has a value 1000 and ALLOWENCES has a value of 250,what will be displayed by the statement DISPLAY GROSS-PAY a.1250 b.01000250 c.01250 d.1.250

3 Answers   TCS,


What is 88 level used for ?

2 Answers  


what happens when a copybook variables are declared using include statement ?

3 Answers   IBM,


Explain about different table spaces.

0 Answers  


what is the difference between start and startbr?

2 Answers  


How can you get the ksds file records into your cobol program?

0 Answers  


Categories