Not getting the allocation of pds with member name



IBM's Command List programming language & Restructured Extended Executor

Not getting the allocation of pds with member name

Postby arya_starc » Thu Feb 16, 2017 9:57 pm

Hi All,

I am trying to reading the member of a pds. But I am not able to get that allocated dataset due to mismatch in the commas.

As on 'say' I get the pds name in single quote and member name seperately because of that it is failed to allocate that dataset.

Below is my rexx code

000500 ADDRESS TSO                                                            
 000600  CC = Listdsi('FILEI FILE')                                            
 000700  FILEI="'"SYSDSNAME"'"                                                  
 000800  CC1 = Listdsi('FILEO FILE')                                            
 000900  FILEO="'"SYSDSNAME"'"                                                  
 001000  WRT = 1                                                                
 001100  X = OUTTRAP(MEMBERS.)                                                  
 001200  "LISTDS" FILEI "MEMBERS"                                              
 001300  X = OUTTRAP(OFF)                                                      
 001400  DO I=7 TO MEMBERS.0                                                    
 001500     X = STRIP(MEMBERS.I)                                                
 001510  /* MEM = FILEI  || "(" || X || ")"  */                                
 001511     MEM = (FILEI(X))                                                    
 001512     SAY MEM                                                            
 001520     "ALLOC FI(IN) DA('"MEM"') SHR REUSE"                                
 001530     "EXECIO * DISKR IN (STEM TAB. FINIS"                                
 001540     "FREE F(IN)"                                                        
 


On line number 1510 when I am doing say, I get the below error message on executing.


'VM.LAT.V823.JCLLIB.SASH1'(PAUCXPT5)                                            
 IKJ56709I INVALID DATA SET NAME, ''VM.LAT.V823.JCLLIB.SASH1'(PAUCXPT5)'        
 IKJ56701I MISSING DATA SET NAME OR *+                                          
 IKJ56701I MISSING NAME OF DATA SET TO BE ALLOCATED                              
 IRX0555E The input or output file IN is not allocated. It cannot be opened for I
 IRX0670E EXECIO error while trying to GET or PUT a record.                      
 IKJ56247I FILE IN NOT FREED, IS NOT ALLOCATED                                  
 'VM.LAT.V823.JCLLIB.SASH1'(PAUC0XB1)                                            
 IKJ56709I INVALID DATA SET NAME, ''VM.LAT.V823.JCLLIB.SASH1'(PAUC0XB1)'        
 IKJ56701I MISSING DATA SET NAME OR *+                                          
 IKJ56701I MISSING NAME OF DATA SET TO BE ALLOCATED                              
 IRX0555E The input or output file IN is not allocated. It cannot be opened for I
 IRX0670E EXECIO error while trying to GET or PUT a record.                      
 IKJ56247I FILE IN NOT FREED, IS NOT ALLOCATED                                  
 
arya_starc
 
Posts: 109
Joined: Mon Sep 21, 2015 1:39 pm
Has thanked: 4 times
Been thanked: 0 time

Re: Not getting the allocation of pds with member name

 

Re: Not getting the allocation of pds with member name

Postby Akatsukami » Thu Feb 16, 2017 10:20 pm

Could it be, Arya-chan, that you do not realize that you need to remove the single quotes, or do not know how?
"You have sat too long for any good you have been doing lately ... Depart, I say; and let us have done with you. In the name of God, go!" -- what I say to a junior programmer at least once a day
User avatar
Akatsukami
Global moderator
 
Posts: 1054
Joined: Sat Oct 16, 2010 2:31 am
Location: Bloomington, IL
Has thanked: 6 times
Been thanked: 51 times

Re: Not getting the allocation of pds with member name

Postby arya_starc » Thu Feb 16, 2017 10:24 pm

here I remove the single quote, but by removing it is taking the mainframe user id as the initial qualifier for the dataset.

here I remove

000600  CC = Listdsi('FILEI FILE')                                            
 000700  FILEI=""SYSDSNAME""                                                  
 000800  CC1 = Listdsi('FILEO FILE')                                            
 000900  FILEO=""SYSDSNAME""  
 
arya_starc
 
Posts: 109
Joined: Mon Sep 21, 2015 1:39 pm
Has thanked: 4 times
Been thanked: 0 time

Re: Not getting the allocation of pds with member name

Postby NicC » Fri Feb 17, 2017 1:20 am

Look at you error message and study it carefully. Does the datasetname(membername) look right? If you think it is right - why? There is nothing magical about the dsn syntax in rexx compared with JCL. Fix it.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 2715
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisys (almost)
Has thanked: 4 times
Been thanked: 107 times

Re: Not getting the allocation of pds with member name

Postby steve-myers » Fri Feb 17, 2017 1:48 am

arya_starc - What akatsukami and Mr. Clousten are trying to tell you is the data set name is 'xxx(member)' not 'xxx'(member)
steve-myers
Global moderator
 
Posts: 1897
Joined: Thu Jun 03, 2010 6:21 pm
Has thanked: 4 times
Been thanked: 200 times


Return to CLIST & REXX

 


  • Related topics
    Replies
    Views
    Last post