Follow Our FB Page << >> for Daily Laughter. We Post Funny, Viral, Comedy Videos, Memes, Vines...

What are decleratives in COBOL ?

What are decleratives in COBOL ?..

Answer / pavan

Declaratives provide special section that are executed when
an exceptional condition occurs. They must be grouped
together and coded at the beginning of procedure division
and the entire procedure division must be divided into
sections. The Declaratives start with a USE statement. The
entire group of declaratives is preceded by DECLARIVES and
followed by END DECLARITIVES in area A. The three types of
declaratives are Exception (when error occurs during file
handling), Debugging (to debug lines with 'D' coded in w-s
section) and Label (for EOF or beginning...) declaratives.

Is This Answer Correct ?    14 Yes 3 No

Post New Answer

More COBOL Interview Questions

why do u need inspect verb?

3 Answers   Patni,

How to Write the RESTART Logic Using COBOL?

4 Answers   GalaxE, L&T, Syntel, TCS,

Explain call by context by comparing it to other calls.

1 Answers  

have in 100 records in a file i want to move only matched records to one output_file1 and nonmathed records are moved to another output_file2 ... any one can provide logic code

3 Answers  

What will happen if a variable is declared as below.. Explain with an example? Working storage section:- 01 WS-VARX PIC X(10) VALUE 'ABCDEFGHIJ'. 01 WS-VARN REDEFINES WS-VARX PIC 9(5) VALUE '12345'. What will happen I am going to Display the WS-VARX and WS- VARN?

6 Answers   Xansa,

What will happen if a variable is declared as below.. Explain with an example? Working storage section:- 01 WS-VARX PIC X(9) VALUE SPACES. 01 WS-VARN REDEFINES WS-VARX PIC 9(9).

8 Answers  

Can the OCCURS clause be at the 01 level?

8 Answers   Oracle,

wht happens if we dnt give scope terminator ?

4 Answers   TCS,

There are 5 fields and 1000 records in a file. Unload it into an array. Write the syntax for declaration and how will you unload it.

0 Answers  

How to read records which is in sequential file in reverse order ? Exp. 1 2 3 4 5 . i want 5 4 3 2 1?please clear my doubt any one

9 Answers   IBM,

select TURE Statement(s) aboUt eject statemenet in cobol? a)The eject statememnt must be the only statement on the line b.It causes the program to edit abnormally c. eject statement can be written in either area A or area B d. specifies that the next source statement is to be printed at Top of the next page e.The EJECTstatement has no effect on the compilation of the source program itself

2 Answers  

what is subscript in cobol?give realtime example?

2 Answers   Wipro,