On Wed, 14 Jan 2015 22:11:35 -0500, Shmuel Metz (Seymour J.) wrote:
>
>>But, ISTR reading long ago that DYNAMNBR is policed by the TSO
>>ALLOCATE command and that BPXWDYN is exempt from the limit.
>
>The ALLOCATE command is jusy another customer of DYNALLOC and it would
>make no sense to put a restriction there. Most allocations are done
>via DAIR or directly via DYNALLOC.
> 
A little experimenting shows that (at our site?) there is a base number of 5
and the DYNAMNBR coded on the EXEC statement is added to that.  So:

//STEP  EXEC  PGM=IKJEFT01,DYNAMNBR=3
    ...
/* Rexx main program. */
trace C
do J = 100 to 122
    RC = BPXWDYN( 'alloc DSN('userid()'.TEST'J') new delete' ,
        'rtddn(D) msg(WTP)' )
    if RC<>0 then leave J
    say 'Allocated' D;  end J

do I = 1 to 11
    address 'TSO' 'allocate dsn(TEST'I') new delete'
    if RC<>0 then leave I;  end

exit( RC )

... successfully allocates 23 data sets with BPXWDYN.  ALLOCATE
allocates 7 more and fails on the 8th.

ISTR in that discussion long ago that there's a flag passed to SVC 99
telling it whether to enforce DYNAMNBR.  ALLOCATE tells it to enforce;
BPXWDYN tells it not to enforce.

So, perhaps the answer to the OP might be to use BPXWDYN instead
of ALLOCATE, if possible.

-- gil

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to