Interviewer). Can we delete a record from ESDS?
Me). No, we cannot delete a record from ESDS
Interviewer). Have you ever tried it?
Me). No. But I have read it that we cannot delete a record from ESDS
Interviewer). That is just a theoretical concept. I have deleted a record from ESDS many times.
That was the discussion that happened b/w me and interviewer. Still, I am not sure how to delete a record from ESDS?
Can anyone please throw some light on it?
Thanks
Tricky question asked at IBM
-
- Posts: 5
- Joined: Tue May 11, 2010 8:15 pm
- Skillset: CICS, DB2, IMS-DB
- Referer: through ibmmainframes.com
- dick scherrer
- Global moderator
- Posts: 6268
- Joined: Sat Jun 09, 2007 8:58 am
Re: Tricky question asked at IBM
Hello,
While the interviewer may not have actually lied, i believe he came very close. . .
Records cannot be deleted from an ESDS. At least never that i've heard/read about. . .
One way that is sometimes used to indicate a deleted record is to place an x'FF' in the first byte and all of the programs that read the file need to look for this and bypass that record. These records are still in the file. . .
While the interviewer may not have actually lied, i believe he came very close. . .
Records cannot be deleted from an ESDS. At least never that i've heard/read about. . .
One way that is sometimes used to indicate a deleted record is to place an x'FF' in the first byte and all of the programs that read the file need to look for this and bypass that record. These records are still in the file. . .
Hope this helps,
d.sch.
d.sch.
- MrSpock
- Global moderator
- Posts: 809
- Joined: Wed Jun 06, 2007 9:37 pm
- Skillset: REXX, JCL, DFSORT, Syncsort, Axway MFT, Connect:Direct, FTP, SFTP
- Referer: ibmmainframes.com
- Location: Raleigh NC USA
- Contact:
Re: Tricky question asked at IBM
I just wonder what the point was of even asking such a question, other than to provoke an argument? It certainly seems to be discriminatory, since I wonder if only an IBM insider might be able to answer it.
-
- Posts: 5
- Joined: Tue May 11, 2010 8:15 pm
- Skillset: CICS, DB2, IMS-DB
- Referer: through ibmmainframes.com
Re: Tricky question asked at IBM
Thanks for the reply
-
- Posts: 3
- Joined: Thu Jun 01, 2017 6:36 pm
- Skillset: JCL, COBOL, DB2, CICS, VSAM, DFSORT
- Referer: internet
Re: Tricky question asked at IBM
record can be deleted from ESDS dataset but physically record will be there. It is not possible to physically delete record from ESDS. Record can be marked as deactivated record. Never tried though but have read it somewhere.
Hope this helps.!!
Hope this helps.!!
-
- Global moderator
- Posts: 3720
- Joined: Sat Dec 19, 2009 8:32 pm
- Skillset: Systems programming, SAS, COBOL, CICS, JCL, SMS, VSAM, etc.
- Referer: other forum
- Location: Dubuque, Iowa, USA
Re: Tricky question asked at IBM
7 years after the question was asked, I doubt it will help very much.Hope this helps.!!
-
- Posts: 3
- Joined: Thu Jun 01, 2017 6:36 pm
- Skillset: JCL, COBOL, DB2, CICS, VSAM, DFSORT
- Referer: internet
Re: Tricky question asked at IBM
Robert Sample wrote:7 years after the question was asked, I doubt it will help very much.Hope this helps.!!
Will definitely help people who will search on this topic and end up at this page.
-
- Global moderator
- Posts: 3720
- Joined: Sat Dec 19, 2009 8:32 pm
- Skillset: Systems programming, SAS, COBOL, CICS, JCL, SMS, VSAM, etc.
- Referer: other forum
- Location: Dubuque, Iowa, USA
Re: Tricky question asked at IBM
Except your answer is misleading and only partially correct.Will definitely help people who will search on this topic and end up at this page.
Once a record is written to an ESDS, there will be data located starting at that RBA as long as the ESDS data set exists. Saying
is not a correct statement. If the application is coded to designate a bit or byte as indicating the record is invalid, then the application can treat the record as deleted even though there is still data in the record. This is what you callrecord can be deleted from ESDS dataset
If the application is not coded to do this, then it will read the data and treat it as valid. The record being marked as "deactivated" is an APPLICATION convention and has nothing to do with the reality of what is stored in the ESDS data set. Some applications will replace the data in the "deactivated" record with LOW-VALUES or HIGH-VALUES (X'00' or X'FF') to prevent attempting to use the data for anything.Record can be marked as deactivated record
The only way to truly delete data from an ESDS is to unload the data into another data set, delete and define the ESDS, and load back the desired data into the ESDS (skipping the records that are to be deleted from the ESDS either on the unload or the reload).
-
- Posts: 3
- Joined: Thu Jun 01, 2017 6:36 pm
- Skillset: JCL, COBOL, DB2, CICS, VSAM, DFSORT
- Referer: internet
Re: Tricky question asked at IBM
Robert Sample wrote:Except your answer is misleading and only partially correct.Will definitely help people who will search on this topic and end up at this page.
Once a record is written to an ESDS, there will be data located starting at that RBA as long as the ESDS data set exists. Sayingis not a correct statement. If the application is coded to designate a bit or byte as indicating the record is invalid, then the application can treat the record as deleted even though there is still data in the record. This is what you callrecord can be deleted from ESDS datasetIf the application is not coded to do this, then it will read the data and treat it as valid. The record being marked as "deactivated" is an APPLICATION convention and has nothing to do with the reality of what is stored in the ESDS data set. Some applications will replace the data in the "deactivated" record with LOW-VALUES or HIGH-VALUES (X'00' or X'FF') to prevent attempting to use the data for anything.Record can be marked as deactivated record
The only way to truly delete data from an ESDS is to unload the data into another data set, delete and define the ESDS, and load back the desired data into the ESDS (skipping the records that are to be deleted from the ESDS either on the unload or the reload).
Whatever I have read I had posted but never tried it. Thanks for explaining it quite in detail. Now it will definitely help.
-
- Similar Topics
- Replies
- Views
- Last post
-
- 2
- 2275
-
by Pedro
View the latest post
Tue Feb 27, 2024 4:44 am