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
 
Diff. between subscript and index with examples

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe Interview Questions
View previous topic :: :: View next topic  
Author Message
karthi_ind

Active User


Joined: 24 Feb 2004
Posts: 131
Location: Chennai

PostPosted: Tue May 04, 2004 10:10 pm    Post subject: Diff. between subscript and index with examples
Reply with quote

hello everybody

1. Explain call by value and call by reference with examples.

2. Explain STRING function WITH POINTER option.

3. Explain Static Call and Dynamic call with examples.

4. Diff. between subscript and index with examples.

5. Diff. between Search and Search All.

Plz answer these questions early. These are mostly asked interview questions.

bye

karthi G.
Back to top
View user's profile Send private message

mvs_butta

New User


Joined: 23 Dec 2003
Posts: 13

PostPosted: Wed May 05, 2004 5:57 pm    Post subject:
Reply with quote

These are all basic questions , you can find the answers in any standard cobol book or refer to any manual
Back to top
View user's profile Send private message
pankajupadhyay
Warnings : 1

New User


Joined: 04 May 2007
Posts: 13
Location: pune

PostPosted: Sun May 06, 2007 7:16 pm    Post subject:
Reply with quote

if u want to sand only value of a particular variable from main pgm to sub pgm then its called called call by value, in this method main pgm and sub pgm use diffrent memory location .
when u use call by refrence that means u are sending address of identifier which u sending from main pgm to sub pgm , in that case sending and reciving feild use same memory location. ex

MAIN PGM.
W-S SECTION.
77 A PIC 999 VALUE IS 20.
77 B PIC 999 VALU IS 30
77 C PIC 999 VALUE ZEORS.
PROC.. DIV..

CALL 'SUBPGM' USING CALL BY VALUE A,B.
CALL BY REFRENCE C.
DISPLAY A
DISPLAY B
DISPLAY C
---------------------------------------------------------
SUB PGM.
L-K SECTION.
77 P PIC 999.
77 Q PIC 999.
77 R PIC 999.
PROCEDURE DIVISION USING P, Q ,R.
COMPUTE C = A + B.
DISPLAY C.

-----------------------------
OUT PUT
A = 20
B= 30
C= 50
P =20
Q= 30
R= 50
Here c and r using same memory location
but a, b and p,q are not
Back to top
View user's profile Send private message
pankajupadhyay
Warnings : 1

New User


Joined: 04 May 2007
Posts: 13
Location: pune

PostPosted: Sun May 06, 2007 7:22 pm    Post subject: Diff. between subscript and index with examples
Reply with quote

subscript is integer variable which u define in a w-s section
but index is displacement which u write along with table declaration
with occurs clause
Back to top
View user's profile Send private message
pankajupadhyay
Warnings : 1

New User


Joined: 04 May 2007
Posts: 13
Location: pune

PostPosted: Sun May 06, 2007 7:26 pm    Post subject: Diff. between Search and Search All.
Reply with quote

search is seq. search but search all use for binary search.
search is good for small records and search all good for big records

and u can also add diff b/w seq and binary search
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 May 06, 2007 11:11 pm    Post subject:
Reply with quote

Hello,

You will find additional info about each of your questions if you search the forums.

Each has already been answered.
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 -> Mainframe Interview Questions All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Confusion b/w index and subscript Deepak kumar25 Mainframe Interview Questions 7 Thu Aug 31, 2017 6:50 am
No new posts SQL - select data available in index Nileshkul DB2 3 Mon Jun 26, 2017 1:30 am
No new posts setting new limit Key values for inde... srilata83 DB2 1 Fri Feb 10, 2017 9:24 pm
No new posts Order BY AND Index Nileshkul DB2 2 Sat Dec 31, 2016 6:33 pm
No new posts Several errors during building altern... Andi1982 JCL & VSAM 11 Wed Jul 06, 2016 7:39 pm

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