My requirement is : I am passing number of seconds I want my program to wait through JCL.
Calling CEE3DLY as : Call "CEE3DLY" USING WAIT-TIME
WAIT-TIME is having the no of seconds passed through JCL and was defined in data division as: PIC S9(9) BINARY
Problem I am facing:
Getting S0C4 when I am trying to call CEE3DLY"
Error is : "CEE3204S The system detected a protection exception (System Completion Code=0C4)"
Though this error is removed when i invoke cobol inbuilt function of date just before calling the CEE3DLY as shown below(for example):
MOVE FUNCTION CURRENT-DATE (9:8) TO CURR-TIME
Call "CEE3DLY" USING WAIT-TIME
In this case my program works successfully.
So I was wondering how is protection exception (S0C4) removed in later case.
Thanks in advance for the time spent on my doubt.
Using IBM utility CEE3DLY to invoke a delay in cobol program
Moderators: dbzTHEdinosauer, Moderator Group
-
- Member
- Posts: 2
- Joined: Thu Apr 19, 2012 8:31 am
- Location: India
Suggest you reconsider what you are trying to do.
Many organizations (most, in my long experience) will not permit a batch job to just sit in an initiator. Why does someone believe there is a need for a delay after the job begins executing?
How is curr-time defined? Is it part of wait-time?
Is the link edit different when the 2 different compiles are run?
Many organizations (most, in my long experience) will not permit a batch job to just sit in an initiator. Why does someone believe there is a need for a delay after the job begins executing?
How is curr-time defined? Is it part of wait-time?
Is the link edit different when the 2 different compiles are run?
Have a good one
-
- Member
- Posts: 2
- Joined: Thu Apr 19, 2012 8:31 am
- Location: India
Hi DikDude
Thanks for you reply.
I very well agree what you said, but basically what I am doing is converting a Assembler program which is using STIMER Macro to Cobol.
So for this I need to put delay in my COBOL program too.
I have defined wait-time and curr time as:
01 WAIT-TIME PIC S9(9) BINARY.
01 CURR-TIME PIC 9(8).
I have defined wait-time as binary because CEE3DLY utility expects input as full word binary in range from 0 to 3600
Link Edits are same in both the compiles.
Thanks for you reply.
I very well agree what you said, but basically what I am doing is converting a Assembler program which is using STIMER Macro to Cobol.
So for this I need to put delay in my COBOL program too.
I have defined wait-time and curr time as:
01 WAIT-TIME PIC S9(9) BINARY.
01 CURR-TIME PIC 9(8).
I have defined wait-time as binary because CEE3DLY utility expects input as full word binary in range from 0 to 3600
Link Edits are same in both the compiles.
Hello,
Just because the code has "always" used STIMER does not mean that should remain "forever". Depending on the requirement, it may be accomplished thru the Scheduling System for the environment.
If you are forced to implement the delay, why not clone the old assembler code that issues the STIMER and create a new "delay" assembler module. You could call this from the COBOL code and basically be where you are today.
Sorry i don't have any CEE3DLY experience.
Just because the code has "always" used STIMER does not mean that should remain "forever". Depending on the requirement, it may be accomplished thru the Scheduling System for the environment.
If you are forced to implement the delay, why not clone the old assembler code that issues the STIMER and create a new "delay" assembler module. You could call this from the COBOL code and basically be where you are today.
Sorry i don't have any CEE3DLY experience.
Have a good one
- dbzTHEdinosauer
- Moderator
- Posts: 981
- Joined: Mon Oct 02, 2006 8:31 pm
besides your problem is a syntax error,
you could not even be bothered to code the instruction properly.
refer to an LE manaul for proper syntax of CEE3DLY.
the invokation of current_date probably loaded a register,
that was still loaded when your incorrectly coded instruction was invoked.
really all first grader stuff,
use the proper syntax and a lot of your problems go away.
you could not even be bothered to code the instruction properly.
refer to an LE manaul for proper syntax of CEE3DLY.
the invokation of current_date probably loaded a register,
that was still loaded when your incorrectly coded instruction was invoked.
really all first grader stuff,
use the proper syntax and a lot of your problems go away.
Dick Brenholtz
JCL, SQL and code in programs have an irritating habit of doing what you say,
not what you meant.
JCL, SQL and code in programs have an irritating habit of doing what you say,
not what you meant.
FREE TUTORIALS
Tutorials
Free tutorials from mainframegurukul
- JCL Tutorial
Covers all important JCL concepts. - Cobol Tutorial
This tutorials covers all Cobol Topics from STRING to COMP-3. - DB2 Tutorial
DB2 Tutorial focuses on DB2 COBOL Programming. - SORT Tutorial
This Tutorial covers all important aspects of DFSORT with examples - CICS Tutorial
This CICS tutorial covers CICS concepts and CICS Basics, CICS COBOL Programming.
Interview
Mainframe Interview questions
- Cobol Interview Questions
50+ Interview Questions - JCL Interview Questions
50+ Interview Questions - DB2 Interview Questions
100+ Interview Questions - CICS Interview Questions
70+ Interview Questions - VSAM Interview Questions
27 Interview Questions
Other References
Mainframe Tools and others
- XPEDITER Reference
Explains how we can debug a program - FILEAID Reference
Explains how to browse , edit and delete datasets - Change Man Reference
Quick Start tutorial on Changeman - Abend Reference
Important Abend codes explained - FaceBook Page
MainframeGurukul FaceBook Page - LinkedIn Page
MainframeGurkul Linkedin Page