On size error option, COBOL Programming


 If after an arithmetic expression, the result exceeds the highest value which can be accommodated in the result; this error is termed as size error. To take an illustration, let A and B be two elementary items with pictures 99 & 999 respectively. Also assume that the present values of the two fields are 35 & 980 correspondingly. Now, the execution of the statement ADD A to B causes a size error. This is because the result field of B is not big enough to hold the result of the addition, specifically, 1015.

Whenever a size error occurs, the contents of the result field after the operation is unpredictable.  Though, the processing is not-terminated and the computer will continue with the execution of the next statement regardless of the fact that a size error occurred. 


Posted Date: 10/17/2012 1:25:08 AM | Location : United States

Related Discussions:- On size error option, Assignment Help, Ask Question on On size error option, Get Answer, Expert's Help, On size error option Discussions

Write discussion on On size error option
Your posts are moderated
Related Questions
DATA RECORD CLAUSE: The DATA RECORD clause, documents the record names defined for the file. For illustration, DATA RECORDS ARE REC-1, REC-2, REC-3 that means there are 3diffe

PROGRAM FOR CONDITION NAMES: We have to write a simple program to demonstrate Condition names usage.  identification division.   program- id.   environment division.

NESTED IF STATEMENT:   The then and else statement of an IF statement can hold other IF statements. The involved IF statements in their turn may also hold other IF statements

REWRITE STATEMENT: The REWRITE statement has the format for a relative file as shown below, REWRITE record-name  [ FORM identifier ]

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

PROGRAM FOR SCREEN SECTION:  identification division.   program- id.   environment division.   data division.   working-storage section.   01  a pic 9(2) value

Direct Organization: Besides the relative or indexed organization, also a direct access file can be designed to have what is termed as direct organization.  In this organizati

calculate simple interest

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

Data Division: The Data Division is a part of the COBOL program where every data item processed by the program is described. It is very important to note that unless a data