Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Code to create QSAM dataset

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IMS DB/DC
View previous topic :: :: View next topic  
Author Message
pingte

Active User


Joined: 03 Dec 2005
Posts: 120
Location: india

PostPosted: Tue Oct 16, 2007 2:54 pm    Post subject: Code to create QSAM dataset
Reply with quote

PART 1: Will the below mentioned code create QSAM dataset?
Code:

//IDCAMS1  EXEC PGM=IDCAMS                     
//SYSPRINT DD SYSOUT=A                         
//SYSIN    DD *                               
 DEFINE GDG (NAME(X.QSAM) -
            LIMIT(48) NOEMPTY SCRATCH)         
/*


Code:

//ABCDEF EXEC IMSPAPI,MBR=IMSPROG,PSB=IMSPSB,DBRC=Y,
//BKO=N,MON=N,IRLM=Y,IRLMNM=IRLM,DMPDEST=STATVIEW
//XYZ      DD DSN=X.QSAM(+1),         
//            DISP=(NEW,CATLG),UNIT=T3480,               
//            DCB=(LRECL=2387,BLKSIZE=23476,RECFM=VB),   
//            LABEL=EXPDT=99365,VOLUME=(,,,10)


PART 2: IF you are given a file name, how will you determine if it's QSAM (i mean what attributes we need to look into) ?

PART3 : Is a QSAM always VB on TAPE?
Back to top
View user's profile Send private message

murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1439
Location: Bangalore,India

PostPosted: Tue Oct 16, 2007 3:06 pm    Post subject:
Reply with quote

pingte,

Quote:
Is a QSAM always VB on TAPE?

No. Other formats are also allowed.

Quote:
IF you are given a file name, how will you determine if it's QSAM (i mean what attributes we need to look into) ?

Are you taking in terms of IMS?


Quote:
Will the below mentioned code create QSAM dataset?

First step creates GDG base. Where second step creates generation (ps/qsam) for the above gdg.
Back to top
View user's profile Send private message
pingte

Active User


Joined: 03 Dec 2005
Posts: 120
Location: india

PostPosted: Tue Oct 16, 2007 3:22 pm    Post subject:
Reply with quote

Thanks for your ans.
I have some more Q's pertaining to QSAM... Can you throw little more light on them ...

PART1:
Quote:
Is a QSAM always VB on TAPE?

No. Other formats are also allowed.

What are the other formats allowed?
And is TAPE complusory for QSAM?

Part 2:
Quote:
IF you are given a file name, how will you determine if it's QSAM (i mean what attributes we need to look into) ?

Are you taking in terms of IMS?

Yes i would like to know in terms of IMS...
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1439
Location: Bangalore,India

PostPosted: Tue Oct 16, 2007 3:37 pm    Post subject:
Reply with quote

pingte,

Quote:
Yes i would like to know in terms of IMS...

Look in DBD.

Quote:
What are the other formats allowed?

Like FB.

Quote:
And is TAPE complusory for QSAM?

No. You can use dasd also (again dpends on size)... but in IMS its not tape (generally).
Back to top
View user's profile Send private message
pingte

Active User


Joined: 03 Dec 2005
Posts: 120
Location: india

PostPosted: Tue Oct 16, 2007 3:57 pm    Post subject:
Reply with quote

Can you please tell me which attributes to look at?

And if the QSAM is on tape, how will we look at the attributes using SHOW command .... ?
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1439
Location: Bangalore,India

PostPosted: Tue Oct 16, 2007 4:01 pm    Post subject:
Reply with quote

Pingte,

Quote:
Can you please tell me which attributes to look at?

Take one PS(QSAM) and PDS. Try using 'S' against these. You will find some difference (letting you to learn on your own).

Quote:
Can you please tell me which attributes to look at?

Use LISTCAT .
Back to top
View user's profile Send private message
pingte

Active User


Joined: 03 Dec 2005
Posts: 120
Location: india

PostPosted: Tue Oct 16, 2007 4:12 pm    Post subject:
Reply with quote

I used LISTCAT ENT(/) ALL .. these were the results..

I think NONVSAM tells it is a QSAM /PS .. Correct me if i am wrong!

I am not sure what FSQEN means...

Code:

NONVSAM ------- X.Y.Z.G001V001           
     IN-CAT --- CATALOG.A.NONVSAM                         
     HISTORY                                                 
       DATASET-OWNER-----(NULL)     CREATION--------2007.271

        RELEASE----------------2     EXPIRATION------0000.000                   
      VOLUMES                                                                   
        VOLSER------------858588     DEVTYPE------X'78048081'     FSEQN---------
---------1                                                                     
      ASSOCIATIONS                                                             
        GDG------X.Y.Z                                     
      ATTRIBUTES                                                               
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Tue Oct 16, 2007 5:02 pm    Post subject:
Reply with quote

Hi,

QSAM...pingte..Curiosity...check this link. icon_smile.gif

Further I can provide this, In IBM mainframe operating systems, a queued sequential access method (QSAM) is one of the access methods for files, or more properly data sets. QSAM files are unkeyed, with the records placed one after another, according to entry order. A program can process these files only sequentially, retrieving (with the READ statement or GET macro instruction) records in the same order as they are in the file. Each record is placed after the preceding record.

QSAM files can be on tape, direct access storage devices (DASDs), unit-record devices, and terminals. QSAM processing is best for tables and intermediate storage.

To process QSAM files in a program, a programmer could use COBOL language statements that:

Identify and describe the QSAM files in the ENVIRONMENT DIVISION and the DATA DIVISION.
Process the records in these files in the PROCEDURE DIVISION.
Back to top
View user's profile Send private message
Bitneuker

CICS Moderator


Joined: 07 Nov 2005
Posts: 1105
Location: The Netherlands at Hole 19

PostPosted: Thu Oct 18, 2007 2:56 pm    Post subject:
Reply with quote

Is this an IMS topic bcause of this? I don't really understand what it's doing here icon_question.gif
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IMS DB/DC All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Copy 4 byte of data from the last rec... arunsoods DFSORT/ICETOOL 9 Fri Oct 06, 2017 12:15 pm
No new posts opening a dataset after reading it fr... arunsoods DFSORT/ICETOOL 5 Wed Oct 04, 2017 3:54 pm
No new posts Speed-up/reduce CPU use of code prino PL/I & Assembler 0 Tue Sep 26, 2017 12:05 am
No new posts Create procedure issues -628 when add... chandraBE DB2 1 Mon Sep 18, 2017 12:16 pm
No new posts How do I create a mainframe monitorin... anjali.bisht All Other Mainframe Topics 4 Fri Sep 01, 2017 2:20 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us