Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


01 WS-NAME PIC X(10) OCCURES 2. by this we can get ws-name 2
times. My qustion is how can we access the second name

Answers were Sorted based on User's Feedback



01 WS-NAME PIC X(10) OCCURES 2. by this we can get ws-name 2 times. My qustion is how can we access..

Answer / veena

occurs can never be used in the 01 level. and when the
clause is used in 02 level, the variable has to be in the
level below that.

01 ws-name1.
02 ws-name2 occurs 2 times.
03 ws-name. pic x(10).

and also pic clause cannot be used in the same statement of
the occurs clause.

Is This Answer Correct ?    16 Yes 7 No

01 WS-NAME PIC X(10) OCCURES 2. by this we can get ws-name 2 times. My qustion is how can we access..

Answer / venkat

The OCCUR keyword can not be used in 01 level variable. But
it can be used in level below 01.

Eg:
01 WS-NAME.
02 WS-NAM-X PIC X(10) occurs 2 times.

01 Ws-TEST PIC X(10) value spaces.


We can access the second name variable WS-NAM-X(2).

Eg 1. MOVE WS-NAM-X(2) to Ws-TEST.
2. Display WS-NAM-X(2).

Is This Answer Correct ?    8 Yes 0 No

01 WS-NAME PIC X(10) OCCURES 2. by this we can get ws-name 2 times. My qustion is how can we access..

Answer / sriharichallagundla

occurs can never be used in the 01 level. and when the
clause is used in 02 level, the variable has to be in the
level below that.

01 ws-name1.
02 ws-name2 occurs 2 times.
03 ws-name. pic x(10).

Is This Answer Correct ?    8 Yes 1 No

01 WS-NAME PIC X(10) OCCURES 2. by this we can get ws-name 2 times. My qustion is how can we access..

Answer / m.raghu

01 ws-name.

02 ws-name1 occurs 2 times.
03 ws-name2 pic x(10).


we can refer to second occurence element is: ws-name1(2).

Is This Answer Correct ?    4 Yes 0 No

01 WS-NAME PIC X(10) OCCURES 2. by this we can get ws-name 2 times. My qustion is how can we access..

Answer / sree

by using perform

Is This Answer Correct ?    0 Yes 5 No

Post New Answer

More COBOL Interview Questions

What kind of error is trapped by on size error option?

0 Answers  


01 ws-p pic 9(2). 01 ws-q pic 9(2) value 01. 01 ws-r pic 9(2) value 99. p.d. compute p = q + r what will be result of p ans(00) but my question is that how i got 10 on the place of 00. (truncation will ocuure on right side not left). please tell me ?

6 Answers   L&T,


Suppose i have a variable with s9(18)v99 comp3 . what is the size of variable . If s9(18) comp3 is 10 bytes . There should be some difference between two allocations ? Thanks krishna chaitanya

2 Answers   CSC,


for an INITIALIZE and what keyword allows for an override of the default.

2 Answers  


What is diff betn PS and ESDS file? What is the diffrent compiler options in cobol and there discription? What is retrive nth maximum salary from salary DB2 table. Can we redefine COM-3 variable with varchar variable?

4 Answers  


What does MAXCC 3 means? It is used in one my codes.

2 Answers   Wipro,


wht happens if we dnt give scope terminator ?

4 Answers   TCS,


s9(18) comp-3:: What is the size of memory it takes internally?

4 Answers  


Hi pls anybody tell me about " ANALYSIS DOCUMENT PREPARATION AND ESTIMATION OF TASK " (in real time project)."I want to update a sequential file in my project" for that purpose i need both structures i mean analysis document and estimation of task.

0 Answers  


When is a scope terminator mandatory?

3 Answers  


what is the default print format? in cobol

3 Answers   HSBC,


what is mainframe? what is the mainframe software ? what is use in s/w field?

7 Answers   CSE,


Categories