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

problem with control card


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

New User


Joined: 19 Aug 2003
Posts: 20
Location: kolkata

PostPosted: Wed Aug 20, 2003 10:09 am
Reply with quote

hi,
I have a problem while using control cards in my jcl.The problem is as follows.

I have coded a new cobol program and passing data from control card as input.In the FD section if i won't mention BLOCK CONTAINS 0 RECORDS my jcl is abending by giving S0C1-04 error.

can any one explain why it's so happening icon_question.gif ...if I'm using SYSIN DD * the jcl is running fine...so what's the difference
Back to top
View user's profile Send private message
mcmillan

Site Admin


Joined: 18 May 2003
Posts: 1210
Location: India

PostPosted: Wed Aug 20, 2003 3:46 pm
Reply with quote

prasadrachuri wrote as: wrote:


I have coded a new cobol program and passing data from control card as input.In the FD section if i won't mention BLOCK CONTAINS 0 RECORDS my jcl is abending by giving S0C1-04 error.


Which COBOL compiler/version you are running? BLOACK CONTAINS CLAUSE is not necessary for VS COBOL II & IBM COBOL. Please tell about your compiler, then we will discuss a lot....
Back to top
View user's profile Send private message
prasadrachuri

New User


Joined: 19 Aug 2003
Posts: 20
Location: kolkata

PostPosted: Wed Aug 20, 2003 4:30 pm
Reply with quote

Dear Mcmillan,
i got the same problem when i use compiler version I and III.
icon_exclaim.gif
Back to top
View user's profile Send private message
mcmillan

Site Admin


Joined: 18 May 2003
Posts: 1210
Location: India

PostPosted: Thu Aug 21, 2003 8:21 am
Reply with quote

Dear,

Please clarify the following:

1. Which compiler: VS COBOL II OR IBM COBOL & Which Version?

2. Which type of FILE (seq/rel/ind)you have on the program?

3. Give the DCB parameters of your File

4. If possible can you send me that progeam>>>
Back to top
View user's profile Send private message
prasadrachuri

New User


Joined: 19 Aug 2003
Posts: 20
Location: kolkata

PostPosted: Thu Aug 21, 2003 12:13 pm
Reply with quote

1. Which compiler: VS COBOL II OR IBM COBOL & Which Version?
I'm using VS COBOL II version III

2. Which type of FILE (seq/rel/ind)you have on the program?
In the program it is used as a sequential file

I have place the data which is a input to my program in a member lets call it as MEMBER1 in PDS XYZ.ABCD.PQRS

and i have used in this in my jcl as follows..

//cardfile dd dsn=XYZ.ABCD.PQRS(MEMBER1),disp=shr

i hope now i'm clear...

Prasad rachuri
Back to top
View user's profile Send private message
mdtendulkar

Active User


Joined: 29 Jul 2003
Posts: 237
Location: USA

PostPosted: Thu Aug 21, 2003 7:12 pm
Reply with quote

Hello prasadrachuri,

Did you copied the control card from some other card and then made changes to it??? This can give a problem.

Try creating the control card a fresh...

May be this will help you.

Regards

Mayuresh Tendulkar
Back to top
View user's profile Send private message
prasadrachuri

New User


Joined: 19 Aug 2003
Posts: 20
Location: kolkata

PostPosted: Fri Aug 22, 2003 10:21 am
Reply with quote

hello Mayuresh,
your right i have copied the control card from some other card and then made changes to it...

so what makes the difference??...can you explain why the program looks for BLOCK CONTAINS 0 RECORDS if the control card copied rfom another...

can u explain me in detail....

Thanks in advance
prasad rachuri
Back to top
View user's profile Send private message
mdtendulkar

Active User


Joined: 29 Jul 2003
Posts: 237
Location: USA

PostPosted: Fri Aug 22, 2003 10:37 am
Reply with quote

Hello prasadrachuri,

I dont know the exact answer to the problem...
but this is what i have learnt from my previous experiences.

But still try to explain it...
Plz correct me if am wrong anywhere...

This kind of problem occurs when you try to copy a file having a single record to other file

when you copy it from ISPF's 3.3 option, it tries to allocate the file by matching the source file's DCB parameters (DCBMODEL) and it does not check the actual physical attributes of the records present in the file and

Due to this sometime it can create problems and you can see the LRECL to be of 0 characters (even if you have a record of more lenght). It can give a problem in program.

Look into the PROFILE of the dataset. (by 'S' at 3.4 option)


Please try creating the control card a fresh...this might solve the problem.

I have tried to make this description as confusing as possible...
icon_confused.gif

Hope you will not mind...
Please let me know the outcome.

Hope this helps you,

Regards

Mayuresh Tendulkar
Back to top
View user's profile Send private message
prasadrachuri

New User


Joined: 19 Aug 2003
Posts: 20
Location: kolkata

PostPosted: Fri Aug 22, 2003 11:20 am
Reply with quote

Hi Mayuresh,
I have traied in your way but still getting problem...
Back to top
View user's profile Send private message
mdtendulkar

Active User


Joined: 29 Jul 2003
Posts: 237
Location: USA

PostPosted: Fri Aug 22, 2003 1:42 pm
Reply with quote

Hello prasadrachuri,

I will try to create this kind of scenario at my end and will let you know more on this.

Meantime can you please cut-paste the sysout messages you are receiving???

That will help me finding the problem.

I will surely get back to you on this

Regards

Mayuresh Tendulkar
Back to top
View user's profile Send private message
prasadrachuri

New User


Joined: 19 Aug 2003
Posts: 20
Location: kolkata

PostPosted: Fri Aug 22, 2003 3:32 pm
Reply with quote

Hello Mayuresh,
I'll be very thankful to you if u solve & explain me the problem..
here i'm giving the message that i got in sysout..


CEE3250C The system or user abend S001 R=00000004 was issued.
From compile unit PROG1 at entry point PROG1 at compile unit offset +00C39E84 at address 00C41DCC.

and in JESYSMSG

IEC020I 001-4,userid ,proc1,RDR1,1F2D,Y2K326,xxxx.yyyy.zzz
IEC020I DCB EROPT=ABE OR AN INVALID CODE, AND/OR NO SYNAD EXIT SPECIFIED
IEA995I SYMPTOM DUMP OUTPUT
USER COMPLETION CODE=4039 REASON CODE=00000000

sorry for troubling you,hope this info is suffecient for you...need more mail me back..

Thanks in advance..
Prasad rachuri...
Back to top
View user's profile Send private message
mdtendulkar

Active User


Joined: 29 Jul 2003
Posts: 237
Location: USA

PostPosted: Fri Aug 22, 2003 4:11 pm
Reply with quote

Hello prasadrachuri,

Can you do the testing for one more time???

It gave me the same error initially...

IEC020I 001-4
If the return code is 4, for QSAM, ABE or an incorrect value for EROPT
parameter in the DCB and/or no error handling (SYNAD) exit was
specified.

so I tried the following,

//SYSIN DD DSN=CTRRR1T.MYPARM,DISP=SHR,DCB=(EROPT=ACC)

Just use the same file, and give the option as EROPT=ACC in the DCB parameter for that file.

and then try executing the program.

It should work...
It has worked at my end.....

When I looked at the help, it was following

EROPT=ACC or SKP or ABE

For QSAM, provides the option to be executed if an error occurs in reading or writing a block.

ACC = accept block causing error
SKP = skip block causing error
ABE = abend the job step (DEFAULT)

Hope this helps you

I will try to find out the answer as why it got abended? (Why this kind of error occurred while the file was just copied)

Regards

Mayuresh Tendulkar
Back to top
View user's profile Send private message
prasadrachuri

New User


Joined: 19 Aug 2003
Posts: 20
Location: kolkata

PostPosted: Fri Aug 22, 2003 5:37 pm
Reply with quote

Hi Mayuresh,

I have traied to executing my progam by giving DCB=(EROPT=ACC).by giving this the jcl is running fine with out giving any ABEND. but my program is not reading any records in the control card.

you haven't get this problem....
icon_question.gif icon_question.gif icon_question.gif
sorry for troubling you again...

Thanks,
Prasad Rachuri...
Back to top
View user's profile Send private message
mdtendulkar

Active User


Joined: 29 Jul 2003
Posts: 237
Location: USA

PostPosted: Fri Aug 22, 2003 6:48 pm
Reply with quote

Hello Prasad,

Oh oh,
I did not used the display statements in my prog.

icon_sad.gif

I will do it and let you know.

Sorry to trouble you.

Regards

Mayuresh Tendulkar
Back to top
View user's profile Send private message
mdtendulkar

Active User


Joined: 29 Jul 2003
Posts: 237
Location: USA

PostPosted: Fri Aug 22, 2003 7:42 pm
Reply with quote

Hello Prasad,

Here is the explanation about the problem you have faced...

I will try to eloborate the solution as clearly as possible...please let me know if i am not able to convey the idea to you.

Assume:

File1: Source Control Card
File2: New Control Card created



Explanation:

Process you did was to copy the FILE1 from 3.3 option to FILE2.
Probably FILE2 was not existing, so when you tried to allocate the FILE2, the attributs of the FILE1 was referred.

Now when the attributes of FILE1 was referred by mainframe to create FILE2.

But the space allocation of the FILE2 may be more for that DASD volume available at that time for FILE2 are so discreet that, even though you have allocated 1 CYL (suppose), the entire space will be distributed over number of blocks.

So when you do not specify the BLOCK CONTAINS clause, it will give you an error as it will not find the contaguous memory giving you S01C-04 error.

one fine day this can also work....as mainframe allocates files depends on the DASD volumes available. If the space is available, it can use the same volume...otherwise it will use some different.

In your case, it used the same volume...so created problem.

So to avoid this problem...

1) Always allocate a dataset first with the format desired and then edit / update it.
2) Copy it from some other file but specify the parameters


Hope i am clear in my explanation

Please let me know in case of any concerns

Hey experts....help me solving this problem.

Regards

Mayuresh Tendulkar
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Sat Aug 23, 2003 1:05 am
Reply with quote

Hi All,

I'm having a bit of trouble following this thread, so I'll just make my stmts and maybe Prasad can try it.

Don't know why it's giving you an 0C1/0C4, but if you don't code "BLOCK CONTAINS 0" the compiler assumes unblocked recs (BLKSIZE=LRECL). If your input is blocked your pgm abends. If you're using a "community" PDS, chances are it's blocked. I think that's your problem.

To fix it, code "BLOCK CONTAINS 0".

Regards, Jack.
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Sat Aug 23, 2003 1:08 am
Reply with quote

I forgot to mention that the compiler uses the BLKSIZE from the JCL/Catalog for the file when "BLOCK CONTAINS 0" is used.

Jack.
Back to top
View user's profile Send private message
prasadrachuri

New User


Joined: 19 Aug 2003
Posts: 20
Location: kolkata

PostPosted: Tue Aug 26, 2003 11:03 am
Reply with quote

Hi Jack & Mayuresh,
I'm very Thankful to you both for the effort you are paying to solve my problem.This is looks to be small problem but I need to change all my programs.

Mayuresh I think your right some times it's working fine(very less chances)..But still I'm in confusion why it is not reading the data in the member...???...you have any solution to this...???..I hope I'm not eating your brain..


but Mr.Jack has made me confused ...if u don't mind Mr.Jack can you tell me what is actually "community" PDS means...


Prasad Rachuri
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Sat Aug 30, 2003 6:35 am
Reply with quote

Hi Prasad,

By "community" I meant any PDS that's used by a group in your shop (application pgmrs, for example) and is usually created by your systems people.

BTW, I may have had it wrong about BLKSIZE = 0 for input files. Since the file already exists, the DCB info is taken from the catalog or label.

The best thing for you to do is show us the JCL, select/assign, FD, OPEN and READ stmts you use to process the file. This might give one of us an insight as to what is going wrong. You may have a rec description that conflicts with the length of the IP rec. It could be anything. That's why the info is important.

BTW2, a U4039 abend in LE Cobol indicates a Return Code 39 after an OPEN. the result of a conflict between the DCB info supplied by your JCL and the DCB info supplied by your pgm. Do you specify a FILE-STATUS for that file?

Jack.
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 SORT CARD meaning please DFSORT/ICETOOL 3
No new posts Add condition to a FINDREP SORT card DFSORT/ICETOOL 4
No new posts Dynamically build sort control statem... SYNCSORT 18
No new posts JCL sort card - get first day and las... JCL & VSAM 9
No new posts Map Vols and Problem Dataset All Other Mainframe Topics 2
Search our Forums:

Back to Top