In A cobol program , we can use COPY Statement in FILE-
SECTION / WORKING-STORAGE SECTION / ENVIRONMENT DIVIION
basically what is the difference
Answers were Sorted based on User's Feedback
Answer / vikas pujar
At File and WS section we declare variables so copy is used
oftenly in projects , in ENV Division just declare files
ddname and logical file name in Input-output section, so
its not used here.
Copy Copybook1, if this is copybook name this can be used
only once tn program either in file section or ws section,
or else will get error that duplicate varaiable names used.
Copy used at File-Section or WS section behaves same way,
so dont think there is any diff in the way Copy behaves at
diff sections.
Is This Answer Correct ? | 8 Yes | 0 No |
There is no difference.
COPY statement just copy all the lines from the copybook
into the source code.
When we feel some piece of codes are used repeatly then we
can code it into the copylib.
So, it is in our hand where to use COPY.
Is This Answer Correct ? | 3 Yes | 0 No |
Answer / kanika
yes we can copy it any where basically it will copy the
line of code mentioned in another source program.
Is This Answer Correct ? | 4 Yes | 4 No |
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
what is rediffine clause?in what situation it can use?give me real time example?
i want a program using by if, evaluate , string, unstring, perform, occurs?
Write a program to concert an Indexed file into Sequential file?
without performing any operations on a file how can i know whether it contains data or not
what is the minimum number of lines a Cobol program should have to successfully compile and run
11 Answers ABC, Societe Generale,
how we can edit records in vsam data set and non vsam data sets
Did anybody attend the walkin of TCS on 31st July in Gurgaon for any technology,If u have completed 3 round i.e till the HR round,have u received the Offer letter yet? Please let me know.Thanks.
how can count the number of character in feild ?? suppose for instance i have a feild with value ' rajesh sarkar' then how can v count the number of characters whitout spaces...........
why we are using set in searchall?
What is amode(24)?
consider the following two statements MOVE 10 TO N PERFORM PARA-X N TIMES STOP RUN PARA-X MOVE 5 TO N how many times PARA-X willbe exicuted? a.10 b.5 c.infinate d.execution error