Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
ENTRY statement is mandatory for IMS programs?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IMS DB/DC
View previous topic :: :: View next topic  
Author Message
Bharath Nadipally

New User


Joined: 24 Jun 2008
Posts: 22
Location: Hyderabad

PostPosted: Thu Jul 03, 2008 4:26 pm    Post subject: ENTRY statement is mandatory for IMS programs?
Reply with quote

I have seen some IMS programs with ENTRY statement and some without ENTRY statement.
Can anyone please explain me why?
Back to top
View user's profile Send private message

Sandy Zimmer

Active Member


Joined: 13 Jun 2007
Posts: 826
Location: Wilmington, DE

PostPosted: Thu Jul 03, 2008 8:44 pm    Post subject:
Reply with quote

Did you look to see if these programs actually issue IMS calls? Did you see a statement with the verb "using"? Take a look at the linkage section.
Back to top
View user's profile Send private message
Bharath Nadipally

New User


Joined: 24 Jun 2008
Posts: 22
Location: Hyderabad

PostPosted: Fri Jul 04, 2008 9:40 am    Post subject:
Reply with quote

hi,

Yes, it has 'USING' statement. after posted, i learnt that IMS program can have either 'ENTRY' statement or 'USING' statement depending on Cobol version.
Back to top
View user's profile Send private message
mkarthikeyan

New User


Joined: 07 Aug 2008
Posts: 34
Location: Bangalore

PostPosted: Sun Aug 17, 2008 4:11 am    Post subject: Reply to: ENTRY statement is mandatory for IMS programs?
Reply with quote

What happens if you have both entry point and procedure division with USING verb? where the address is established?
Back to top
View user's profile Send private message
Sandy Zimmer

Active Member


Joined: 13 Jun 2007
Posts: 826
Location: Wilmington, DE

PostPosted: Sun Aug 17, 2008 4:19 am    Post subject:
Reply with quote

You cannot have both statements. The "entry" statement connects directly "talking" to your IMS system. The "using" statement connects to a higher level routine which "talks" to IMS.
Back to top
View user's profile Send private message
mkarthikeyan

New User


Joined: 07 Aug 2008
Posts: 34
Location: Bangalore

PostPosted: Sun Aug 17, 2008 4:21 am    Post subject: Reply to: ENTRY statement is mandatory for IMS programs?
Reply with quote

What happens if you have both entry point and procedure division with USING verb? where the address is established?
Back to top
View user's profile Send private message
Sandy Zimmer

Active Member


Joined: 13 Jun 2007
Posts: 826
Location: Wilmington, DE

PostPosted: Sun Aug 17, 2008 4:28 am    Post subject:
Reply with quote

You cannot have both.
Back to top
View user's profile Send private message
mkarthikeyan

New User


Joined: 07 Aug 2008
Posts: 34
Location: Bangalore

PostPosted: Sun Aug 17, 2008 4:50 am    Post subject: Reply to: ENTRY statement is mandatory for IMS programs?
Reply with quote

Sandy,
We can have both in the program. During migration, from VS-Cobol II to E-cobol I found both Entry and procedure division in a program.

Here is an example

PROCEDURE DIVISION USING PCB-EMPDB.
DISPLAY ' I AM BEFORE ENTRY'.
0000-MAIN-PARA.
ENTRY 'DLITCBL' USING PCB-EMPDB.

i would like to explain how the program acts in two scenario.

First case :
When the program is compiled and link-edit with link control card as
ENTRY DLITCBL, then IMS gives the control to the Entry point.
So the spool we cannot see the display ' I am before Entry'

Second case:
When the program is compiled and link-edit without link control card as
ENTRY DLITCBL, then IMS gives the control to the Procedure division and Entry statement will not be executed. So the spool will the display ' I am before Entry'.
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Sun Aug 17, 2008 6:00 am    Post subject:
Reply with quote

Hello,

And what is your point?

You have just demonstrated that you can use one or the other but not both?

Pick the one you want and use it. As you were told before, you cannot use both in the same program at the same time. . .
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IMS DB/DC All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts pointers on using USS and C programs. Pedro All Other Mainframe Topics 0 Wed Oct 04, 2017 4:38 am
No new posts PLI - printing from multiple programs Pedro PL/I & Assembler 8 Fri Sep 08, 2017 6:36 am
No new posts WER268A OUTREC STATEMENT : SYNTAX E... frozenblood87 SYNCSORT 12 Sat Aug 26, 2017 9:45 pm
No new posts Suppress value reported by BREAK in D... Learncoholic DFSORT/ICETOOL 3 Wed Aug 16, 2017 6:03 pm
No new posts ON 2 AND EVERY 1 - Statement ??? UmeySan COBOL Programming 2 Tue Jul 25, 2017 1:20 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us