What is the difference between PS file and ESDS file?

All sort of Mainframes Interview Questions.
Post Reply
User avatar
Angel
Registered Member
Posts: 93
Joined: Sat Jun 08, 2013 8:13 pm

What is the difference between PS file and ESDS file?

Post by Angel »

Hi,

In a recent interview I've been asked what is the difference between PS file and ESDS file?

Apart from knowing that they both can be accessed sequentially, I could not get a better answer - can someone please help?
User avatar
Anuj Dhawan
Founder
Posts: 2801
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

Re: What is the difference between PS file and ESDS file?

Post by Anuj Dhawan »

You had a good start I think, in the interview! :)

Here is what I'll try to add in:

A very simple thing which you perhaps knew but did not notice & that is - in physical sequential file records are stored in "blocks", where as in VSAM files it's ControlInterval(C.I.).

Other thing is, QSAM (PS) "files" can be created on tapes while the VSAM files cannot.

Said that, ESDS is the which is VSAM-speak for sequential file. Unless 'am mistaken, the original idea was to replace PS by ESDS which, possibly, had faster I/O but with these days of RAID, Cache etc. the DASD perform much faster than they ever did before and perhaps, that's why they never really caught on that well.

Additional functionality of ESDS is that it can be overlayed by an AIX while for sequential files, this can not be done.
Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
User avatar
Anuj Dhawan
Founder
Posts: 2801
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

Re: What is the difference between PS file and ESDS file?

Post by Anuj Dhawan »

An ESDS is essentially a sequential dataset where new records are always inserted at the end. You cannot access records directly with a key. However, you may access specific records with a relative byte address (RBA), if you have or can calculate it. In fact, it's fairly common to see CICS application use an ESDS as a log file to write records in sequential order while retrieving the new record's RBA from the RIDFLD operand of the EXEC CICS WRITE command. If the application squirrels away the RBA it can later retrieve the log record directly. Also note that you cannot physically delete a record from an ESDS. Instead, most applications utilize a "logical delete" scheme where a field in the ESDS record is set to a value indicating the record is no longer valid.
Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
User avatar
Akshya Chopra
Registered Member
Posts: 77
Joined: Mon May 20, 2013 11:32 pm
Algeria

Re: What is the difference between PS file and ESDS file?

Post by Akshya Chopra »

This is a good question, Thanks for posting Angel.
User avatar
Angel
Registered Member
Posts: 93
Joined: Sat Jun 08, 2013 8:13 pm

Re: What is the difference between PS file and ESDS file?

Post by Angel »

Thanks Anuj - this is more than enough for me to remember! :)
User avatar
Anuj Dhawan
Founder
Posts: 2801
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

Re: What is the difference between PS file and ESDS file?

Post by Anuj Dhawan »

Gald that I had been helpful.

Good Luck with Interviews! :)
Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
Post Reply

Create an account or sign in to join the discussion

You need to be a member in order to post a reply

Create an account

Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute

Register

Sign in

Return to “Interview Questions.”