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

File Tailoring -- Temporary dataset in skeleton


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

New User


Joined: 01 Feb 2010
Posts: 8
Location: Dallas, TX, USA

PostPosted: Fri Dec 01, 2017 3:12 am
Reply with quote

I am generating the jcl using file tailoring. The skeleton jcl uses the temporary dataset &&dataset1 which get converted to &dataset1 in the generated jcl.

&& gets converted to &

Code:
ORIGINAL CODE:                                   
//OUTFILE  DD DSN=&&DATASET1,DISP=(NEW,PASS,DELETE)
                                                 
CONVERTED CODE:                                   
//OUTFILE  DD DSN=&DATASET1,DISP=(NEW,PASS,DELETE)


Please advice.
Back to top
View user's profile Send private message
sergeyken

Senior Member


Joined: 29 Apr 2008
Posts: 2023
Location: USA

PostPosted: Fri Dec 01, 2017 3:50 am
Reply with quote

1) JCL rule: both &&DATASET, and &DATASET are considered as the same temporary DSNAME

2) File Tailoring rule: in order to generate each single apostrophe, two '&' characters in a row must be used:
'&&' --> '&'
'&&&&' --> '&&'
Back to top
View user's profile Send private message
samzee71

New User


Joined: 01 Feb 2010
Posts: 8
Location: Dallas, TX, USA

PostPosted: Fri Dec 01, 2017 4:01 am
Reply with quote

Thanks alot
Back to top
View user's profile Send private message
Willy Jensen

Active Member


Joined: 01 Sep 2015
Posts: 712
Location: Denmark

PostPosted: Fri Dec 01, 2017 2:55 pm
Reply with quote

Quote:
1) JCL rule: both &&DATASET, and &DATASET are considered as the same temporary DSNAME

Unless there is a SET symbol (or system symbol if activated for batch jobs) with that name, so I would advocate always using double ampersands for temporary datasetnames.
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 Compare 2 files and retrive records f... DFSORT/ICETOOL 3
No new posts FTP VB File from Mainframe retaining ... JCL & VSAM 8
No new posts Extract the file name from another fi... DFSORT/ICETOOL 6
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
Search our Forums:

Back to Top