Open statement, COBOL Programming

OPEN STATEMENT:

Whenever a READ or a WRITE operation is executed on a file, then it should be open. The opening of a file may be completed with the help of the OPEN verb. With the OPEN verb it should be also indicated whether the file must be opened as an input file or output file. If it is an input file, only the reading is possible, while in the case of an output file, only writing is possible. The file once opened remains open until it is closed by the CLOSE statement. The OPEN statement in its easiest form is as shown below:

1847_open statement.png

 

Posted Date: 10/16/2012 5:33:27 AM | Location : United States







Related Discussions:- Open statement, Assignment Help, Ask Question on Open statement, Get Answer, Expert's Help, Open statement Discussions

Write discussion on Open statement
Your posts are moderated
Related Questions
PROGRAM USING OCCURS CLAUSE: We have to write a simple program to demonstrate Occurs Clause. Get the employee details for 3 persons and compute the total salary. identifica

SEQUENTIAL FILE CREATION AND REWRITING: We have to write a program to create a student file with just two fields: sno i.e. Student Number and same i.e. Student Name. Add a few

IF ... ELSE STATEMENT: We are familiar with an easy form of the IF statement. The common form of the IF statement is as shown below: Each of the statement-1 and statem

single program how may when statement has used

SEARCH VERB: The SEARCH verb is used to position elements in one-dimensional tables. Let us consider the following problem. Assume that each element of a table consists of thr

PERFORM WITH TIMES OPTION: The format of a PERFORM TIMES statement is as shown below: Illustration:   A)  Perform the para-2 5 times. In this situation the specifie

Example of constructing an arithmetic expression: An arithmetic expression may be proceeded by a + or - sign. These operations are known as unary + or unary - operators. Il

There are some restrictions when these procedures are used. (i) The Procedure should not contain any SORT/MERGE statement. (ii) An explicit transfer of the control outside

Illustration of Perform with varying option: A) Perform para-3 varying the k from 1 by 1 until k > 10. Here para-3 will be constantly executed 10 times (For k=1,2,3, .....1

Examples - Edit characters for numeric data: The following illustration illustrates the use of Z editing characters. The character b is used to indicate the space character an