How to delete the records of a dataset through cobol
programme?We should not use jcl utilitities like IDCAMS.
Answers were Sorted based on User's Feedback
Answer / janardhan
we can delete by usinf the files concept.
if case of sequential file there is no direct delete option.
for this
1) read the record and rewrite with spaces.
2) read record from one file and write it into another file
by excluding the record which has to be deleted.
if case of indexed file we can directly delete the record
as it contains the indexed no.
same for relative files.
Is This Answer Correct ? | 5 Yes | 0 No |
Answer / vivek chandrasekaran
If the file we are using is VSAm file then we can go for Key mentioned,
If it is a sequential file we have to read till the 49th record then needs to delete the 50th record, this is the main disadvantage with Sequential files.
Syntax for deleting record.
DELETE file_name RECORD
Is This Answer Correct ? | 1 Yes | 0 No |
In INITIALIZE what is Repalcing Word will do
Write a program to concert an Indexed file into Sequential file?
How to code fscode 10 in cobol program? Where yoy code in your pgm?give ans for the question.
hi dudes.....can any one help me..... what is SET TO TRUE all about,anyway?
we can use set true for condition names.. similarly can we code set to false in cobol pgm? will it work?
Should I use STOP RUN in the sub program??why?
Difference between array and sub-script ?
have in 100 records in a file i want to read first 3 records and skip next 3 records and agan i want to read 3 records and again i want to skip 3 records...
2 Answers ITC Indian Tobacco Company, PNP, TCS,
can anybody post me about file-aid and changemen tools pls and give me reference if any mainframe guys are there
How To move a value to an array using move verb?
what is difference between the sysabend and userabend?
What R 2 of the common forms of the EVALUATE STATEMENT ?