View previous topic :: View next topic
|
Author |
Message |
ensameer
New User
Joined: 15 Mar 2005 Posts: 4 Location: Chennai
|
|
|
|
Hi friends,
Plz answer for the below query.
Does the ENTRY statement used in sub-programs only.
Please explain with example where this ENTRY statement is used
-Sameer
09443605966 |
|
Back to top |
|
|
priya
Moderator
Joined: 24 Jul 2003 Posts: 568 Location: Bangalore
|
|
|
|
Quote: |
Does the ENTRY statement used in sub-programs only. |
The question is wrong. As for as I know, you cannot use ENTRY statement in subprograms. You can use only in main program.
Please explain with example where this ENTRY statement is used
Code: |
ENTRY PGM2 USING X, Y. |
|
|
Back to top |
|
|
mmwife
Super Moderator
Joined: 30 May 2003 Posts: 1592
|
|
|
|
Hi Sameer,
The ENTRY stmt was designed primarily for specifying alternate entry pts to subpgms. The primary entry pt is supplied automatically by the compiler.
I've never tried to execute a pgm from the JCL EXEC stmt using an alternate EP. It should be easy enough to test. But remember, that subpgms usually process data passed from the CALLer. This you can't simulate from the JCL. (You can, really, but it's messy.) |
|
Back to top |
|
|
ensameer
New User
Joined: 15 Mar 2005 Posts: 4 Location: Chennai
|
|
|
|
Hi,
Thanks priya and mmwife for ur reply.
So, is this ENTRY statement used to enter into some entry point of a subprogram ? Is this same as PERFORM statement which is used to enter into a para of same program.
-Sameer
09443605966 |
|
Back to top |
|
|
|