VSAM Tips.

A Mainframe-Tip a Day keeps the bugs away!
Forum rules
All of these Tips/Tuning-suggestions should be tested your own, at your shop, prior to use in Prod.
Previous topicNext topic
User avatar

Topic Author
Anuj Dhawan
Founder
Posts: 2624
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Zodiac: Sagittarius

VSAM Tips.

Post by Anuj Dhawan » Fri May 24, 2013 11:13 pm

1. CICS, DB2, IMS can process records in existing VSAM data-sets but can't create the data-set. Even you can process VSAM data sets in COBOL programs only after you create them with access method services.



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

Topic Author
Anuj Dhawan
Founder
Posts: 2624
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Zodiac: Sagittarius

Re: VSAM Tips.

Post by Anuj Dhawan » Tue May 28, 2013 8:46 pm

2. To specify dummy VSAM dataset in a JCL, Code AMP=’AMORG’ . This parameter tells the OS to treat the file as VSAM file. E.g.:

Code: Select all

//NOVSAMIO DD DUMMY,AMP=’AMORG’


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

Topic Author
Anuj Dhawan
Founder
Posts: 2624
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Zodiac: Sagittarius

Re: VSAM Tips.

Post by Anuj Dhawan » Wed May 29, 2013 11:58 pm

3. If you want to make VSAM-data-set read-only, use INHIBIT along with ALTER command:

Code: Select all

//STEP1 EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
ALTER -
SECRET.KSDS.DATA -
INHIBIT
ALTER -
SECRET.KSDS.INDEX -
INHIBIT
/*
//*
Notice that the ALTER command is used with DATA and INDEX and not with the cluster.


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

Topic Author
Anuj Dhawan
Founder
Posts: 2624
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Zodiac: Sagittarius

Re: VSAM Tips.

Post by Anuj Dhawan » Thu Jun 06, 2013 9:18 pm

4. A VSAM data-set created with REUSE can be treated as a new data-set at any subsequent time. In a way, you can say that VSAM equivalent of temp data-set is to create VSAM file with REUSE option.


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

Topic Author
Anuj Dhawan
Founder
Posts: 2624
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Zodiac: Sagittarius

Re: VSAM Tips.

Post by Anuj Dhawan » Tue Aug 20, 2013 6:47 pm

5. IDCAMS Utility can't be executed without the SYSPRINT and SYSIN DD names.


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.


Neeraj N
Registered Member
Posts: 47
Joined: Tue Aug 20, 2013 12:49 pm

Re: VSAM Tips.

Post by Neeraj N » Thu Sep 05, 2013 10:12 am

Quite a good number of tips, Thanks for sharing them.

Regards,
Neeraj



User avatar

Topic Author
Anuj Dhawan
Founder
Posts: 2624
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Zodiac: Sagittarius

Re: VSAM Tips.

Post by Anuj Dhawan » Thu Sep 05, 2013 12:32 pm

Thanks for the feedback Neeraj - glad, you find them helpful.

Regards,


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.


Kapil Sharma
Registered Member
Posts: 43
Joined: Sun Sep 29, 2013 1:46 am
Location: India

Re: VSAM Tips.

Post by Kapil Sharma » Thu Oct 03, 2013 7:42 pm

Thanks for the tip no. 3, I just used it. :)


Thanks,
Kapil

User avatar

Topic Author
Anuj Dhawan
Founder
Posts: 2624
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Zodiac: Sagittarius

Re: VSAM Tips.

Post by Anuj Dhawan » Thu Oct 03, 2013 8:02 pm

Great - nice to know that! :)

Regards,


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

Topic Author
Anuj Dhawan
Founder
Posts: 2624
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Zodiac: Sagittarius

Re: VSAM Tips.

Post by Anuj Dhawan » Sun Nov 17, 2013 12:01 pm

6. Advice: One should remove Catalog Orphans from the Catalog, (if you're in the capacity of doing it).


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

Topic Author
Anuj Dhawan
Founder
Posts: 2624
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Zodiac: Sagittarius

Re: VSAM Tips.

Post by Anuj Dhawan » Wed Nov 20, 2013 3:43 pm

7. As an Application Developer (assuming COBOL as the Application language) - for sequential access of VSAM, request more data buffers. For random access, request more index buffers.

One should specify both BUFND and BUFNI when ACCESS IS DYNAMIC.

Avoid coding additional buffers unless your application will run interactively; then code buffers only when response-time problems arise that might be caused by delays in input and output.


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

Topic Author
Anuj Dhawan
Founder
Posts: 2624
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Zodiac: Sagittarius

Re: VSAM Tips.

Post by Anuj Dhawan » Wed Nov 20, 2013 3:48 pm

8. As a COBOL Application Developer, if you can choose this -for 'best performance', access records sequentially.

Dynamic access is less efficient than sequential access, but more efficient than random access. Random access results in increased EXCPs because VSAM must access the index for each request.


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.

Previous topicNext topic

Return to “Tip Of the Day.”