Alan,

QCMDEXC itself runs in the default activation group.  However, any commands that it runs will be run as if run from the prior call stack entry -- in other words, if QCMDEXC had been called from an ILE activation group, the command you run will also be in that activation group.

This is critical for stuff like OVRDBF since it defaults to OVRSCOPE(*ACTGRPDFN), meaning that the override will apply to the activation group it was run from.

Likewise, if you write your own command "MYCMD" and its CPP has ACTGRP(*CALLER), you could run it via QCMDEXC, and MYCMD's CPP would be in the same activation group as QCMDEXC had been called from.

-SK


On 2/23/2021 4:02 PM, Alan Cassidy wrote:
Discussion came up at work.

My understanding is that QCMDEXC runs as if it at the same call level as the program that calls it. Do I remember correctly? So long since I worked that stuff.

It obviously runs in the same job as the program (even if it runs a SBMJOB), but somebody at work said it runs in the default activation group, "because commands run in the default AG".

I don't think so, but is that true? Maybe it is for the CPP program that executes QCMDEXC, but I would think that a user command, for example, runs in the activation group of its command processing program.

--Alan


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2021 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.