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
 
LISTDSI error

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
MARINA JOSEPH

New User


Joined: 11 Jun 2009
Posts: 61
Location: chennai

PostPosted: Tue Oct 27, 2009 1:54 pm    Post subject: LISTDSI error
Reply with quote

Hi,

I am trying to obtain the RECFM of a file.



Code:
IF SYSDSN("'"FILEIN"'") = 'OK' THEN   

 DO                                   

   DSINFO = LISTDSI(FILEIN)           

                                     

   SAY 'REASON' SYSREASON             

   IF DSINFO == 0 THEN               

   DO                                 

                                     

    SAY 'RECFM' SYSRECFM             

   END                               

END                                   


It throws error code as 16, and the REASON code is 5 which mean file is not cataloged.



But the file does exist. Its Volume serial . . . is : TSO006.


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

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Tue Oct 27, 2009 2:11 pm    Post subject:
Reply with quote

Make sure that the input dataset is within quotes
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2360
Location: Israel

PostPosted: Tue Oct 27, 2009 2:17 pm    Post subject:
Reply with quote

if you used quotes for SYSDSN, you need them also in LISTDSI. Both functions use the same method to access datasets info.

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

New User


Joined: 11 Jun 2009
Posts: 61
Location: chennai

PostPosted: Tue Oct 27, 2009 2:19 pm    Post subject:
Reply with quote

Thanks for all you replies, it worked.
Back to top
View user's profile Send private message
MARINA JOSEPH

New User


Joined: 11 Jun 2009
Posts: 61
Location: chennai

PostPosted: Mon Nov 02, 2009 1:56 pm    Post subject: FETCHING A VARIABLE
Reply with quote

Hi,


I have a record as below:-



10 ACT-POL-APPL-NAME PIC X(18)



Code:
POS2 = POS('PIC',REC.I)

LN1 = WORD(STRING,POS2-2)



Can I give statement like this to fetch the word ‘10’?

Currently I am not able to fetch the same by giving this statement.

Thanks.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Mon Nov 02, 2009 2:49 pm    Post subject:
Reply with quote

POS and WORD are two seperate functions whose results should not be mixed up.

POS gives a physical position of the search argument within the string to be searched, whilst word gives a relative word number within the string to be searched.
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 -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts IEW2456E error when link-editing a C ... Senthilraj JCL & VSAM 0 Fri Oct 13, 2017 3:12 pm
No new posts FTP Skip or ignore error and process ... AJAYREDDY All Other Mainframe Topics 3 Wed Sep 27, 2017 8:12 pm
No new posts Assembler Macro Copybook converted to... Ziquilix PL/I & Assembler 4 Tue Sep 26, 2017 3:07 am
No new posts FUSE - IBM MQ - CICS integration error Kevin Vaz CICS 1 Mon Sep 18, 2017 4:31 pm
No new posts Reply MQ open error Vignesh Sid COBOL Programming 6 Thu Sep 07, 2017 6:02 pm

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