I hv ten records in ps file and i hv say some 15 records in
vsam file .i hv empno and age in ps file n
empno,empname,dept n desig in vsam file. i hv 2 read the ps
file n check wid matching empno in vsam file and then
insert all fields from ps and vsam into db2 table....plz
help in writin the procedure division
File FD for PS
01 PS-FILE
05 PS-EMP-NO
05 PS-EMP-AGE
File FD for VSAM
01 VSAM-FILE
05 VSAM-EMP-NO-------->RECORD KEY
05 VSAM-EMP-NAME
05 VSAM-EMP-DEPT
PROCEDURE DIVISION
PERFORM UNTILL END OF PS FILE
READ PS FILE
READ VSAM-FILE KEY IS PS-EMP-NO
IF VSAM-FILE-STAUTS = '00'
EXEC SQL
INSERT INTO TABLE EMPLOY WITH VALUE 'PS-EMP-NO', 'PS-EMP-
AGE', 'VSAM-EMP-NAME' 'VSAM-EMP-DEPT'
END-EXEX
END-PERFORM.
| Is This Answer Correct ? | 4 Yes | 0 No |
comp-3 field occupy?
Explain complete concept of table handling in COBOL with an example?
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
if we have " ibm mainframe ",in that how to remove first and last leading space eg:"ibm mainframe" like that the answer we need
What is the difference between NEXT SENTENCE and CONTINUE?
What is the significance of the PROGRAM-ID paragraph? If this name doesnt match with the name of the COBOL program, does it make a difference? Is the name specified in the PROGRAM-ID paragraph used as a name for the load module or any such thing?
) how do u code after getting data?
What is the difference between binary search and sequential search?
Can a Search can be done on a table with or without Index?
What type of Call you would use if you don;t want the control back to the calling program?
what is record label is empty or standard in file description of data division?
What are the cobol coding sheets?