IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

LISTDSI is not working for me.


IBM Mainframe Forums -> CLIST & REXX
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
vasan_4u

New User


Joined: 28 Jun 2005
Posts: 35
Location: chennai

PostPosted: Mon Dec 17, 2007 9:45 pm
Reply with quote

This is the code I have and its giving me RC as 16 could anyone help me out.

Code:
FILE = 'LSV.F.COLLQ'       
ADDRESS TSO                 
RC = LISTDSI("'"FILE"'")   
SAY RC                     
IF RC=0 THEN               
SAY 'ENTER'                 
DO                         
  DSN = SUBSTR(SYSDSORG,1,2)
  SAY DSN                   
END                       
Back to top
View user's profile Send private message
superk

Global Moderator


Joined: 26 Apr 2004
Posts: 4652
Location: Raleigh, NC, USA

PostPosted: Mon Dec 17, 2007 9:54 pm
Reply with quote

vasan_4u wrote:
... its giving me RC as 16 ...


My guess is that the file doesn't exist. What does the SYSREASON variable show?
Back to top
View user's profile Send private message
vasan_4u

New User


Joined: 28 Jun 2005
Posts: 35
Location: chennai

PostPosted: Mon Dec 17, 2007 10:03 pm
Reply with quote

Yes as you said the file was not correct it should be 'LSV.F.COLLQ.CLUSTER'

One more question how do I get to know that if a given Dataset is a VSAM or GDG or PS.

I tried with LISTDS and LISTC command both of them dint work for me could you provide me with a sample code.
Back to top
View user's profile Send private message
superk

Global Moderator


Joined: 26 Apr 2004
Posts: 4652
Location: Raleigh, NC, USA

PostPosted: Mon Dec 17, 2007 10:10 pm
Reply with quote

You're on the right track. The SYSDSORG variable will have the value for the dataset organization:

PS - Physical sequential
PO - Partitioned organization
VS - VSAM

The TSO command LISTDS should've worked also.
Back to top
View user's profile Send private message
kiran_chr
Currently Banned

New User


Joined: 02 Aug 2006
Posts: 2

PostPosted: Tue Dec 18, 2007 3:20 am
Reply with quote

Give like this it will work
PULL NAME
NAME1=LISTDSI(NAME) ---> dont put any quotes
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2358
Location: Israel

PostPosted: Tue Dec 18, 2007 12:16 pm
Reply with quote

kiran_chr -

Why "dont put any quotes"??? icon_question.gif

O.
Back to top
View user's profile Send private message
vasan_4u

New User


Joined: 28 Jun 2005
Posts: 35
Location: chennai

PostPosted: Wed Dec 19, 2007 9:51 pm
Reply with quote

thanks for the help ..

this is how i used it and it worked for me

Code:
X = OUTTRAP("MSG.");                     
"LISTDS '"PDSN"' MEMBERS"               
X = OUTTRAP("OFF.");                     
PARSE VAR MSG.3 RECFM LRECL BLKSIZE DSORG
SAY RC                                   
SAY LRECL                               
SAY DSORG
Back to top
View user's profile Send private message
Ganesh.Deokar

New User


Joined: 30 Sep 2005
Posts: 26
Location: Buffalo,NY

PostPosted: Fri Dec 21, 2007 1:21 am
Reply with quote

Try these links:

publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/IKJ2A304/4.4.2?DT=19951106081441#FIGLSTCDES


publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/IKJ2A304/4.4.2.2?SHELF=&DT=19951106081441&CASE=


Regards,
Ganesh
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> CLIST & REXX

 


Similar Topics
Topic Forum Replies
No new posts PD not working for unsigned packed JO... DFSORT/ICETOOL 5
No new posts Def PD not working for unsigned packe... JCL & VSAM 3
No new posts ICETOOL with JOINKEY for Big record l... DFSORT/ICETOOL 12
No new posts JCL JOB Cancel/Purge Not Working JCL & VSAM 6
No new posts OMVS Shell Script not working properly. All Other Mainframe Topics 1
Search our Forums:

Back to Top