On size error option, COBOL Programming

ON SIZE ERROR OPTION:

 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
PROGRAM FOR DIVIDE VERB:   We have to write an easy program to elaborate DIVIDE verb. You can also use edit characters in the program. Identification division. Program-

PROGRAM FOR INVENTORY  We have to write a program to update the inventory file. Consider 2 files,viz, invfile an tranfile. Invfile has 3 fields pno,name,qty. Tranfile has 3 fil

READ STATEMENTS: The common format for the read statements is as shown bellow. Format 1: READ file-name RECORD [ INTO   identifier ] [  ;  AT   END     imperative-s

REWRITE STATEMENT: As in the situation of a relative file, the REWRITE statement needs that the file should be opened in the I-O mode, and if the SEQENTIAL access mode is spec

PERFORM WITH UNTIL OPTION: The format is as shown below: Illustration:  A) Perform p-3 until i > 5. Here p-3 will be executed whenever i B)  Perform p-2 thru

Evaluate is like a case statement & Evaluate  stamenet can be used to replace nested Ifs. The difference b/w EVALUATE and case is that there is no 'break' is required for EVALUATE

DELETE STATEMENT : The file should be opened in the I-O mode. If the access is SEQUENTIAL, the INVALID KEY phrase must be specified. Rather than, the last input-output state

can we move spaces to numeric field

ROUNDED OPTION: Let us consider the DATA DIVISION entries which are as shown below: Now, subsequent to the execution of the statement ADD A B GIVING C, the C will hold

PROCEDURE DIVISION statements for the relative files: The statements OPEN, CLOSE, READ, WRITE and REWRITE that are available for sequential files are also available for the re