Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
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
 
Data set is allocated to another job or user

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

New User


Joined: 01 Apr 2009
Posts: 33
Location: Rome - Italy

PostPosted: Wed Aug 03, 2016 4:31 pm    Post subject: Data set is allocated to another job or user
Reply with quote

Hi all,
I have a problem with my new rexx...

I copy two pd member from a lib to another;
After i remane the two member;
After I modify the two member with MACRO;
At this point is all OK!

At end my REXX submit the first member contained a job.
At this point is all OK!

The last exec of the job submitted is the submit of second member.
At thie point the first job returns RC 12 (DATA SET IS ALLOCATED TO ANOTHER JOB OR USER)

This is the code:

ADDRESS TSO
"ALLOC FI(SYSUEXEC) DA("LIBSPU") SHR REU"
"ALTLIB ACT USER(EXEC)"
ADDRESS ISPEXEC
"LMINIT DATAID(SPU) DATASET("LIBSPU") ENQ(SHRW)"
"LMINIT DATAID(REX) DATASET("LIBREX") ENQ(SHRW)"
"LMCOPY FROMID("SPU") TODATAID("REX") FROMMEM("EXPORT") REPLACE"
"LMCOPY FROMID("SPU") TODATAID("REX") FROMMEM("IMPORT") REPLACE"
"LMINIT DATAID(REX) DATASET("LIBREX") ENQ(EXCLU)"
"LMOPEN DATAID("REX") OPTION(OUTPUT)"
"LMMDEL DATAID("REX") MEMBER("RENEXP")"
"LMMDEL DATAID("REX") MEMBER("RENIMP")"
"LMMREN DATAID("REX") MEMBER("EXPORT") NEWNAME("RENEXP")"
"LMMREN DATAID("REX") MEMBER("IMPORT") NEWNAME("RENIMP")"
"VPUT (FIN) SHARED"
"VPUT (AMB) SHARED"
"EDIT DATASET("LIBREX"("RENEXP")) MACRO("RIBALTAM")"
"EDIT DATASET("LIBREX"("RENIMP")) MACRO("RIBALTAM")"
ADDRESS TSO
JOB="'"LIBREX"("RENEXP")'"
"SUBMIT " JOB

I think I must go out the dataset... How???
Back to top
View user's profile Send private message

Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1775
Location: Bloomington, IL

PostPosted: Wed Aug 03, 2016 7:22 pm    Post subject:
Reply with quote

I do not see invocations of LMCLOSE and LMFREE.
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 1868
Location: UK

PostPosted: Fri Aug 05, 2016 7:22 pm    Post subject:
Reply with quote

I also do not see the use of code tags so I am not going to bother to confirm, or otherwise, Akatsukami's response.
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 Question related to Data dictionary f... rexx77 SYNCSORT 3 Thu Aug 31, 2017 7:23 am
No new posts Extract Data till prev hour balaji81_k DB2 16 Fri Aug 25, 2017 9:25 pm
No new posts FTP data transfer from PC to Mainfram... AJAYREDDY All Other Mainframe Topics 8 Wed Aug 23, 2017 9:59 pm
No new posts Unable to copy data from spool in a d... srikant314 JCL & VSAM 8 Fri Jul 28, 2017 9:10 pm
No new posts Paasing symbolic parameter to instrea... Robert Sample JCL & VSAM 2 Thu Jul 27, 2017 1:22 pm

Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us