Need guidance in dynamic allocation of VSAM in assembler.

HLASM for MVS. PL/I for MVS & Enterprise PL/I for z/OS.
Post Reply
Sukanya A
New Member
Posts: 1
Joined: Fri Aug 08, 2014 3:31 pm

Need guidance in dynamic allocation of VSAM in assembler.

Post by Sukanya A »

Hi,

I can be considered very new to assembler programming but for one assignment I need write line of codes in MVS HLASM which can allocate a VSAM dynamically. Can you please guide me on this?
User avatar
Robert Sample
Global Moderator
Global Moderator
Posts: 1895
Joined: Fri Jun 28, 2013 1:22 am
Location: Dubuque Iowa
United States of America

Re: Need guidance in dynamic allocation of VSAM in assembler

Post by Robert Sample »

This is NOT a task for someone "very new to assembler programming". Just writing an assembler program to access VSAM is not a simple process and should not be undertaken by anyone with less than 1 to 2 years of Assembler experience. Doing the dynamic access complicates the entire program and hence you need to get several years of experience with assembler before you attempt to dynamically allocate VSAM files.
User avatar
Robert Sample
Global Moderator
Global Moderator
Posts: 1895
Joined: Fri Jun 28, 2013 1:22 am
Location: Dubuque Iowa
United States of America

Re: Need guidance in dynamic allocation of VSAM in assembler

Post by Robert Sample »

One additional point I wanted to add: there is no such thing as "a VSAM" data set. All VSAM data sets are ESDS, KSDS, RRDS, LDS -- and each of them have different attributes. ESDS can be accessed sequentially or through the alternate index (if defined). KSDS can be accessed sequentially, directly (by primary key), or by alternate index (if defined). RRDS can be accessed by relative record number or by alternate index (if defined). LDS can be accessed by RBA. So merely saying you want to dynamically allocate "a VSAM" data set is woefully inadequate in providing information that MUST be known to do the allocation. And if you didn't know about the four types of VSAM data sets, you have no business attempting to allocate one in Assembler; if you did know about the four types of VSAM data sets, you need to learn how to ask questions since you did not provide essential information (such as the VSAM type) in your post.
enrico-sorichetti
Global Moderator
Global Moderator
Posts: 826
Joined: Wed Sep 11, 2013 3:57 pm

Re: Need guidance in dynamic allocation of VSAM in assembler

Post by enrico-sorichetti »

unless the TS means ...
allocate as allocate an existing dataset ( at the DD level )
and not
allocate as define a NEW VSAM dataset

in this case the TS should research and read about the use of BPXWDYN
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort 8-)
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 “Assembler & PL/I.”