I  was puzzled by the length of CMDBUFL ...after your explanation Walt, it's 
very clear.
Thank you. I wasn't aware that a TSO parser could be called in IRREVX01 that's 
a great idea..

I saw the length using an Abend macro, being on a test system I can perform 
controlled tests.
We don't want our customers to have issues with the exit..

Scott ford
www.identityforge.com

Tell me and I'll forget; show me and I may remember; involve me and I'll 
understand. - Chinese Proverb


On Apr 12, 2013, at 9:03 PM, Walt Farrell <[email protected]> wrote:

> On Fri, 12 Apr 2013 09:12:45 -0700, Scott Ford <[email protected]> wrote:
>
>> I have a field in a RACF parameter list ...CMDBUFL ..this is the length
>> of the command buffer.
>> It looks like it is x'F8' which is 248 ..bytes. I need to calculate the
>> total length of CMDBUFD which is the incoming buffer. I have a issue with
>> a large amount of userids being passed to our exit..like this
>>
>> CONNECT (id id id id id id id) GROUP(grpid)
>> or
>> CONNECT id GROUP(grpid)
>>
>> I want be able to logically inside me code to decide do i have one id or
>> many..
>
> If I were doing it, I would consider parsing the command using TSO/E Parsing
> services.
>
> But if you're going to do it by yourself, you see if there's an opening ( or
> not. And, actually, it's possible that the command format you get will
> always have the parentheses, even if there's only 1 ID in the list.
>
> But if there's a ( then you find the first non-blank after it, and then look
> for the next blank or ), and that's your first ID. You keep going until
> you've accumulated all of them, and you're done when you get the ) that ends
> that operand.
>
> I don't understand what you mean (in the part I didn't quote) by "the length
> is bugging you". You know the length of the buffer. (And it won't always be
> 248, it could be much longer (probably up to 32768 or so).) You keep going
> until you hit the ) or until you hit the maximum number of user IDs you've
> programmed your code to handle. If you hit your maximum limit, you either
> lose data, or if that's not acceptable to you and your customers you abort
> the command.
>
> --
> Walt

Reply via email to