0
根據MVS JCL參考指南工作啓動請求數據集的獨家控制權之前:JCL數據獨佔訪問設置錯誤
DISP and ENQ: Before starting the first step of a job, the initiator requests
control of all of the data sets in that job by issuing an ENQ for each of them,
using the value specified for DISP to determine the kind of ENQ issued. The
initiator issues the ENQ for each data set at the highest level required for that
data set by any step of the job. For example, if all steps of the job request
shared control of a specific data set (DISP=SHR) then the ENQ for that data set
is requested as SHR. If, on the other hand, any step of the job requests
exclusive control of a specific data set (DISP=NEW, DISP=MOD, or DISP=OLD), then
the ENQ for that data set is requested EXCL.
但是我有兩個不同的行爲:
一)我通過ISPF DATASET_A打開並提交一個使用與DISP =(NEW,CATALOG,DELETE)相同的數據集的JCL。我收到TSO消息是因爲作業請求了數據集,並且直到我通過ISPF發佈數據集時JCL纔會啓動。 b)我提交了2個使用與DISP =(NEW,CATALOG,DELETE)相同的數據集但同時開始的JCL's。
爲什麼作業在並行運行時請求不能獨佔訪問數據集?
兩者如果是這樣的原因,如果我用DISP = MOD或DISP = OLD他們應該請求獨佔訪問,對嗎? – user823959
DISP = OLD意味着它必須已經存在,否則將會失敗,但是如果數據集存在,它確實意味着獨佔訪問。 – Deuian
它也說: '舊 - 表明數據集在這一步之前存在,並且這一步需要獨佔(非共享)使用數據集。' 奇怪,但DISP =(MOD,KEEP,KEEP)滿足我的需求。 – user823959