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

DISP field for temporary dataset


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Prabha
Warnings : 2

New User


Joined: 05 Dec 2005
Posts: 79

PostPosted: Thu Jan 24, 2008 5:15 pm
Reply with quote

When using temporary datasets in JCL, what should be the disposition.
CAn we give new or shr or old??
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Thu Jan 24, 2008 5:16 pm
Reply with quote

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

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Jan 24, 2008 5:23 pm
Reply with quote

Yes, you can use any of those, and as Dick has added, PASS

What problems are you encountering here ?
Back to top
View user's profile Send private message
Prabha
Warnings : 2

New User


Joined: 05 Dec 2005
Posts: 79

PostPosted: Thu Jan 24, 2008 5:45 pm
Reply with quote

Some of our project JCL's are using disp=(new).. So let me know the difference between new and pass.
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Thu Jan 24, 2008 6:36 pm
Reply with quote

Prabha,

Go thru the JCL material available in the 'downloads' section of the forum. New & Pass are two diff values.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Thu Jan 24, 2008 11:02 pm
Reply with quote

Hello,

Use NEW for the first positional parameter of DISP.

Use PASS for the second potitional parameter of DISP.

And i prefer DELETE for the third positional DISP parameter when creating a temporary dataset.

Code:
//TEMPDATA DD DSN=&&TMPSTUF,DISP=(NEW,PASS,DELETE),etc
Back to top
View user's profile Send private message
Bitneuker

CICS Moderator


Joined: 07 Nov 2005
Posts: 1104
Location: The Netherlands at Hole 19

PostPosted: Sat Jan 26, 2008 1:29 am
Reply with quote

I'm a fan of business requirements icon_wink.gif What about disp=mod?
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Sat Jan 26, 2008 1:58 am
Reply with quote

Hello,

For my $.02, there are a couple of good places to use MOD.

One is to append data. Another is to ensure a "housekeeping" step does not fail.

I've seen a few situations where unexpected/invalid results happened due to unintentionally appending to an existing file (one that was not supposed to exist).

Again, not a rule, just a preference. . . icon_smile.gif
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 -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts FINDREP - Only first record from give... DFSORT/ICETOOL 3
No new posts Replace Multiple Field values to Othe... DFSORT/ICETOOL 12
No new posts Map Vols and Problem Dataset All Other Mainframe Topics 2
No new posts Allocated cylinders of a dataset DB2 12
No new posts Sort First/last record of a subset th... DFSORT/ICETOOL 7
Search our Forums:

Back to Top