What is COMP SYNC?
Answers were Sorted based on User's Feedback
Answer / deepak goyal
Causes the item to be aligned on natural boundaries. Can be
SYNCHRONIZED LEFT or RIGHT.
For binary data items, the address resolution is faster if
they are located at word boundaries in the memory. For
example, on main frame the memory word size is 4 bytes.
This means that each word will start from an address
divisible by 4. If my first variable is x(3) and next one
is S9(4) COMP, then if you do not specify the SYNC clause,
S9(4) COMP will start from byte 3 ( assuming that it starts
from 0). If you specify SYNC, then the binary data item
will start from address 4. You might see some wastage of
memory, but the access to this computational field is
faster.
Is This Answer Correct ? | 13 Yes | 0 No |
Answer / padmanabha naidu.p
it will star with wordboundaries.while you are using sync
clause you wiil get slack bytes.
Is This Answer Correct ? | 10 Yes | 4 No |
1)what is use of linkage section? 2)what is difference between comp and comp-3
can we use full outer join with cursors declared in cobol program?
How can I find the maximum value of a field in a file while reading the file dynamically? without using sort function. Suppose i have a file with fields Timestamp, description, teamname, teamnumber.. i have read the file till end and find the maximun value of timestamp which is not in sorted order.. can we use function max(timestamp)?
can we declare s9(9)v9(9) in cobol ? if yes how many bytes it will occupy ?(urgent plz answer it)
can we use 77 level no for Redefines?if we use give an example?
) How do u handle errors in BMS macro
Can printer files (having 133 characters) be of variable length?
ID DIVISION. PROGRAM-ID. PLO. DATA DIVISION. WORKING-STORAGE SECTION. 01 VAR1 PIC 9(2). 01 VAR2 PIC X(2). PROCEDURE DIVISION. ACCEPT VAR2. MOVE VAR2 TO VAR1. STOP RUN. if i give 'PI' in var2 then what will b output of progr. any abend?????
how many bytes does s9(15) occupy in comp1 comp2 and comp3 ?
What is perform what is varying?
How many maximum number of procedures can we write in one COBOL program?
I have a variable account-number declared as comp-3, s9(10) comp-3 in a file. How do i find a particular account number say 123456 in that file?