-
command syntax
We just got a new 515
In the past we could type "DP" and see all spool files (not D SPACE P)
We can't type that command now, the vendor says that was specific to a
System36 environment.
They tell us we now have to type "wrksplf select(*all)"
I do not really want our users to start getting heavy on the CL.
Is there a way I can do something so we can still type DP and have it
kick that off?
-
Re: command syntax
Put this in QGPL/QCMDSRC member DP and compile it with the CRTCMD
statement shown below.
/*********************************************************************/
/* CRTCMD CMD(QGPL/DP) PGM(QCMDEXC) */
/*********************************************************************/
CMD PROMPT('WRKSPLF Shortcut') PARM
KWD(CMD) TYPE(*CHAR) LEN(32) +
CONSTANT('wrksplf select(*all)') PARM KWD(LENGTH)
TYPE(*DEC) LEN(15 5) CONSTANT(32)
Denny
On Thu, 02 Aug 2007 08:50:21 -0600, [email]dan@willcraft.com[/email] wrote:
[color=blue]
>We just got a new 515
>In the past we could type "DP" and see all spool files (not D SPACE P)
>
>We can't type that command now, the vendor says that was specific to a
>System36 environment.
>
>They tell us we now have to type "wrksplf select(*all)"
>
>I do not really want our users to start getting heavy on the CL.
>
>Is there a way I can do something so we can still type DP and have it
>kick that off?[/color]
-
Re: command syntax
On Aug 2, 10:50 am, d...@willcraft.com wrote:[color=blue]
> We just got a new 515
> In the past we could type "DP" and see all spool files (not D SPACE P)
>
> We can't type that command now, the vendor says that was specific to a
> System36 environment.
>
> They tell us we now have to type "wrksplf select(*all)"
>
> I do not really want our users to start getting heavy on the CL.
>
> Is there a way I can do something so we can still type DP and have it
> kick that off?[/color]
You could create a simple command called DP to what you want.
-
Re: command syntax
On Thu, 02 Aug 2007 08:50:21 -0600, [email]dan@willcraft.com[/email] wrote:[color=blue]
> We just got a new 515
> In the past we could type "DP" and see all spool files (not D SPACE P)
>
> We can't type that command now, the vendor says that was specific to a
> System36 environment.
>
> They tell us we now have to type "wrksplf select(*all)"
>
> I do not really want our users to start getting heavy on the CL.
>
> Is there a way I can do something so we can still type DP and have it
> kick that off?[/color]
You can create a command "DP" that calls a CL program that does WRKSPLF
SELECT(*ALL)... Or as a compromise, change the default on the WRKSPLF
command to make *ALL the default for the SELECT() option. Do your users
normally want to see everyone's spooled files, or mostly their own? They
may welcome the regular WRKSPLF defaults if they use their own files
mostly.
--
6. I will not gloat over my enemies' predicament before killing them.
--Peter Anspach's list of things to do as an Evil Overlord
-
Re: command syntax
The following gives the method to effect recreate of a DP command as
part of change management for a new release. This example uses QTEMP,
so choose an appropriate library for the environment:
dltcmd qtemp/DP
crtdupobj wrksplf qsys *cmd qtemp DP
chgcmddft qtemp/DP 'SELECT(*ALL *ALL *ALL *ALL *ALL) ASTLVL(*INTERMED)'
Note: The above was done on v5r3 where there are only five elements
on SELECT; regardless, all but the first element are *ALL on both releases.
Note: Assistance level was specified in the example, because the
SELECT(*ALL) is, as I recall, a poor performing function with *BASIC.
Note: Other LPP [Licensed Program Product] commands since v5r4 may be
'proxy' commands. The first time I was playing around with one of
those, I broke something [accidentally deleted? I do not recall] and
had to restore from another system since I did not have any backups of
the LPP [via SAVLICPGM].
Regards, Chuck
--
All comments provided "as is" with no warranties of any kind
whatsoever and may not represent positions, strategies, nor views of my
employer
[email]dan@willcraft.com[/email] wrote:[color=blue]
> We just got a new 515
> In the past we could type "DP" and see all spool files (not D SPACE P)
>
> We can't type that command now, the vendor says that was specific to a
> System36 environment.
>
> They tell us we now have to type "wrksplf select(*all)"
>
> I do not really want our users to start getting heavy on the CL.
>
> Is there a way I can do something so we can still type DP and have it
> kick that off?[/color]
-
Re: command syntax
There might be several things worth considering when using the
QCMDEXC method versus a duplicate object with changed command
default(s), or a REXX or CL program as an intermediary.
- The program QCMDEXC accepts two INOUT parameters, so a /constant/
may be inappropriate. AFaIK this should not be an issue except for with
use of auto/selective prompting or commands like CHGUSRPRF which use
hidden input parameters which causes the command string to be rewritten.
Any write-back from the CPP over the amount of storage reserved for
the constant can cause storage corruption which may or may not cause
visible problems in execution.
- Using a fully qualified command name may be appropriate versus
defaulting to *LIBL; e.g. QSYS/WRKSPLF, *NLVLIB/WRKSPLF,
*SYSTEM/WRKSPLF, or ALTQSYS/WRKSPLF
- All command parameters should be specified to avoid picking up
changed command defaults in the command that is referenced; if that is
desirable. All command parameters that have dependencies on other
parameters should have the dependent parameter explicitly specified to
avoid DEP or similar validation errors.
- Benefit over CRTDUPOBJ is no requirement to create the object anew
on each release, but individual sources for each customized *CMD might
be more work to maintain than one script of many dlt/crtdup/chgdft. But
for the lack of need to recreate again, there may be little need to keep
each command source.
Regards, Chuck
--
All comments provided "as is" with no warranties of any kind
whatsoever and may not represent positions, strategies, nor views of my
employer
Denny wrote:[color=blue]
> Put this in QGPL/QCMDSRC member DP and compile it with the CRTCMD
> statement shown below.
>
> /******************************************************************/
> /* CRTCMD CMD(QGPL/DP) PGM(QCMDEXC) */
> /******************************************************************/
> CMD PROMPT('WRKSPLF Shortcut')
> PARM KWD(CMD) TYPE(*CHAR) LEN(32) CONSTANT('wrksplf select(*all)')
> PARM KWD(LENGTH) TYPE(*DEC) LEN(15 5) CONSTANT(32)[/color]
-
Re: command syntax
Why can't they just load the S36EE???? It's still there, just not
pre-loaded.
[email]dan@willcraft.com[/email] wrote:[color=blue]
> We just got a new 515
> In the past we could type "DP" and see all spool files (not D SPACE P)
>
> We can't type that command now, the vendor says that was specific to a
> System36 environment.
>
> They tell us we now have to type "wrksplf select(*all)"
>
> I do not really want our users to start getting heavy on the CL.
>
> Is there a way I can do something so we can still type DP and have it
> kick that off?[/color]
-
Re: command syntax
[email]dan@willcraft.com[/email] wrote:[color=blue]
> We just got a new 515
> In the past we could type "DP" and see all spool files (not D SPACE P)
>
> We can't type that command now, the vendor says that was specific to a
> System36 environment.
>
> They tell us we now have to type "wrksplf select(*all)"
>
> I do not really want our users to start getting heavy on the CL.
>
> Is there a way I can do something so we can still type DP and have it
> kick that off?[/color]
We have a number of "shortcut" commands here. Below is an example of 1,
the "W" command. If you type in "W P" (or just "W" since "P" is the
default) you see your spool files. Key in "W W" to work with writers.
/* Command processing program is QCMDEXC */
CMD PROMPT('Various WRK Commands')
PARM KWD(OPTION) TYPE(*CHAR) LEN(32) RSTD(*YES) +
DFT(P) +
SPCVAL((J 'WRKSBMJOB') +
(P 'WRKSPLF') +
(E '?WRKSPLFE') +
(AJ 'WRKACTJOB') +
(O '?WRKOUTQ') +
(INV 'WRKOUTQ FPHOLD') +
(MLB 'WRKMLBBRM') +
(FP 'WRKOUTQ FP*') +
(Z 'WRKOUTQ Z*') +
(JQ '?WRKJOBQ QBATCH') +
(JS '?WRKJOBJS') +
(L '?WRKOBJLCK') +
(SPLF '?WRKSPLF') +
(U 'WRKUSRJOB *ALL *ACTIVE') +
(UA 'WRKUSRJOB') +
(FV 'WRKFAVCMD') +
(ACT 'WRKSYSACT') +
(W 'WRKWTR') +
(WA 'WRKWTR *ALL')) +
EXPR(*YES) PROMPT('Option')
PARM KWD(LENGTH) TYPE(*DEC) LEN(15 5) CONSTANT(32)
Another example, the "M" command.
M: CMD PROMPT('Run DSPMSG Command')
/* Command processing program is QCMDEXC */
PARM KWD(OPTION) TYPE(*CHAR) LEN(32) RSTD(*YES) +
DFT(M) +
SPCVAL((M 'DSPMSG') +
(L 'DSPMSG ACCESS') +
(O 'DSPMSG ORDERS') +
(S 'DSPMSG SPCITMORD') +
(IXS 'WRKMSGQ IXS/*ALL') +
(MM '?DSPMSG')) +
EXPR(*YES) PROMPT('Option')
PARM KWD(LENGTH) TYPE(*DEC) LEN(15 5) CONSTANT(32)
Some of the options are unique to our environment. With a little
imagination, the possibilities for this are almost endless. They can
even be allowed for limited users so users can do things like display
their messages from anywhere.
This is not an original idea of mine, I got it from someone online at
least 15 years ago. The time it has saved our company is nothing short
of amazing.
HTH.
-
Re: command syntax
FWiW: In S/36E the /command/ is D to Display Session, or display the
specified details according to the passed parameter. The OP did suggest
awareness of the difference between their past use of a DP versus _D P_.
The System/36 Environment feature is OPTION(05) of i5/OS.
Regards, Chuck
--
All comments provided "as is" with no warranties of any kind
whatsoever and may not represent positions, strategies, nor views of my
employer
Kirk Goins wrote:[color=blue]
> Why can't they just load the S36EE???? It's still there, just not
> pre-loaded.
>
> [email]dan@willcraft.com[/email] wrote:[color=green]
>> We just got a new 515
>> In the past we could type "DP" and see all spool files (not D SPACE P)
>>
>> We can't type that command now, the vendor says that was specific to a
>> System36 environment.
>>
>> They tell us we now have to type "wrksplf select(*all)"
>>
>> I do not really want our users to start getting heavy on the CL.
>>
>> Is there a way I can do something so we can still type DP and have it
>> kick that off?[/color][/color]
-
Re: command syntax
I was confusing thoughts on QCMDCHK when I made the statements about
QCMDEXC for INOUT; and besides, CPF0005 documents that QCMDCHK prevents
writing back more than what was input.
The parameters on QCMDEXC are not output capable so there is no
concern for command strings that may increase in length.
Regards, Chuck
--
All comments provided "as is" with no warranties of any kind
whatsoever and may not represent positions, strategies, nor views of my
employer
CRPence wrote:[color=blue]
> <<SNIP>>
> - The program QCMDEXC accepts two INOUT parameters, so a /constant/
> may be inappropriate. AFaIK this should not be an issue except for with
> use of auto/selective prompting or commands like CHGUSRPRF which use
> hidden input parameters which causes the command string to be rewritten.
> Any write-back from the CPP over the amount of storage reserved for the
> constant can cause storage corruption which may or may not cause visible
> problems in execution.
> <<SNIP>>[/color]
-
Re: command syntax
All-
Since I am still a 'newbie' in the this programming commands..
How do I create the source file and compile it? Is it under CL or is it
under CMD?
Gil
Jeff Crosby wrote:[color=blue]
> [email]dan@willcraft.com[/email] wrote:
>[color=green]
>> We just got a new 515
>> In the past we could type "DP" and see all spool files (not D SPACE P)
>>
>> We can't type that command now, the vendor says that was specific to a
>> System36 environment.
>>
>> They tell us we now have to type "wrksplf select(*all)"
>>
>> I do not really want our users to start getting heavy on the CL.
>>
>> Is there a way I can do something so we can still type DP and have it
>> kick that off?[/color]
>
>
>
> We have a number of "shortcut" commands here. Below is an example of 1,
> the "W" command. If you type in "W P" (or just "W" since "P" is the
> default) you see your spool files. Key in "W W" to work with writers.
>
>
> /* Command processing program is QCMDEXC */
>
> CMD PROMPT('Various WRK Commands')
>
> PARM KWD(OPTION) TYPE(*CHAR) LEN(32) RSTD(*YES) +
> DFT(P) +
> SPCVAL((J 'WRKSBMJOB') +
> (P 'WRKSPLF') +
> (E '?WRKSPLFE') +
> (AJ 'WRKACTJOB') +
> (O '?WRKOUTQ') +
> (INV 'WRKOUTQ FPHOLD') +
> (MLB 'WRKMLBBRM') +
> (FP 'WRKOUTQ FP*') +
> (Z 'WRKOUTQ Z*') +
> (JQ '?WRKJOBQ QBATCH') +
> (JS '?WRKJOBJS') +
> (L '?WRKOBJLCK') +
> (SPLF '?WRKSPLF') +
> (U 'WRKUSRJOB *ALL *ACTIVE') +
> (UA 'WRKUSRJOB') +
> (FV 'WRKFAVCMD') +
> (ACT 'WRKSYSACT') +
> (W 'WRKWTR') +
> (WA 'WRKWTR *ALL')) +
> EXPR(*YES) PROMPT('Option')
> PARM KWD(LENGTH) TYPE(*DEC) LEN(15 5) CONSTANT(32)
>
>
>
> Another example, the "M" command.
>
> M: CMD PROMPT('Run DSPMSG Command')
> /* Command processing program is QCMDEXC */
>
> PARM KWD(OPTION) TYPE(*CHAR) LEN(32) RSTD(*YES) +
> DFT(M) +
> SPCVAL((M 'DSPMSG') +
> (L 'DSPMSG ACCESS') +
> (O 'DSPMSG ORDERS') +
> (S 'DSPMSG SPCITMORD') +
> (IXS 'WRKMSGQ IXS/*ALL') +
> (MM '?DSPMSG')) +
> EXPR(*YES) PROMPT('Option')
> PARM KWD(LENGTH) TYPE(*DEC) LEN(15 5) CONSTANT(32)
>
> Some of the options are unique to our environment. With a little
> imagination, the possibilities for this are almost endless. They can
> even be allowed for limited users so users can do things like display
> their messages from anywhere.
>
> This is not an original idea of mine, I got it from someone online at
> least 15 years ago. The time it has saved our company is nothing short
> of amazing.
>
> HTH.[/color]
-
Re: command syntax
Gilbert Noetzel wrote:[color=blue]
> All-
>
> Since I am still a 'newbie' in the this programming commands..
>
> How do I create the source file and compile it? Is it under CL or is it
> under CMD?
>
> Gil
>
> Jeff Crosby wrote:[color=green]
>> [email]dan@willcraft.com[/email] wrote:
>>[color=darkred]
>>> We just got a new 515
>>> In the past we could type "DP" and see all spool files (not D SPACE P)
>>>
>>> We can't type that command now, the vendor says that was specific to a
>>> System36 environment.
>>>
>>> They tell us we now have to type "wrksplf select(*all)"
>>>
>>> I do not really want our users to start getting heavy on the CL.
>>>
>>> Is there a way I can do something so we can still type DP and have it
>>> kick that off?[/color]
>>
>>
>>
>> We have a number of "shortcut" commands here. Below is an example of
>> 1, the "W" command. If you type in "W P" (or just "W" since "P" is
>> the default) you see your spool files. Key in "W W" to work with
>> writers.
>>
>>
>> /* Command processing program is QCMDEXC */
>>
>> CMD PROMPT('Various WRK Commands')
>>
>> PARM KWD(OPTION) TYPE(*CHAR) LEN(32) RSTD(*YES) +
>> DFT(P) +
>> SPCVAL((J 'WRKSBMJOB') +
>> (P 'WRKSPLF') +
>> (E '?WRKSPLFE') +
>> (AJ 'WRKACTJOB') +
>> (O '?WRKOUTQ') +
>> (INV 'WRKOUTQ FPHOLD') +
>> (MLB 'WRKMLBBRM') +
>> (FP 'WRKOUTQ FP*') +
>> (Z 'WRKOUTQ Z*') +
>> (JQ '?WRKJOBQ QBATCH') +
>> (JS '?WRKJOBJS') +
>> (L '?WRKOBJLCK') +
>> (SPLF '?WRKSPLF') +
>> (U 'WRKUSRJOB *ALL *ACTIVE') +
>> (UA 'WRKUSRJOB') +
>> (FV 'WRKFAVCMD') +
>> (ACT 'WRKSYSACT') +
>> (W 'WRKWTR') +
>> (WA 'WRKWTR *ALL')) +
>> EXPR(*YES) PROMPT('Option')
>> PARM KWD(LENGTH) TYPE(*DEC) LEN(15 5) CONSTANT(32)
>>
>>
>>
>> Another example, the "M" command.
>>
>> M: CMD PROMPT('Run DSPMSG Command')
>> /* Command processing program is QCMDEXC */
>>
>> PARM KWD(OPTION) TYPE(*CHAR) LEN(32) RSTD(*YES) +
>> DFT(M) +
>> SPCVAL((M 'DSPMSG') +
>> (L 'DSPMSG ACCESS') +
>> (O 'DSPMSG ORDERS') +
>> (S 'DSPMSG SPCITMORD') +
>> (IXS 'WRKMSGQ IXS/*ALL') +
>> (MM '?DSPMSG')) +
>> EXPR(*YES) PROMPT('Option')
>> PARM KWD(LENGTH) TYPE(*DEC) LEN(15 5) CONSTANT(32)
>>
>> Some of the options are unique to our environment. With a little
>> imagination, the possibilities for this are almost endless. They can
>> even be allowed for limited users so users can do things like display
>> their messages from anywhere.
>>
>> This is not an original idea of mine, I got it from someone online at
>> least 15 years ago. The time it has saved our company is nothing
>> short of amazing.
>>
>> HTH.[/color][/color]
Commands, so use CTRCMD. Remember, the PGM parm is QCMDEXC, like this:
CRTCMD CMD(W) PGM(QCMDEXC)
-
Re: command syntax
Jeff -
thank you for giving me a starting point.
I think I can make it from here foward...this is a neat little short
cut.. and it does cut down lots of keyboarding...
I wonder if we can take the next steps...Verbal Command? anyone done
that yet?
Gil
Jeff Crosby wrote:[color=blue]
> Gilbert Noetzel wrote:
>[color=green]
>> All-
>>
>> Since I am still a 'newbie' in the this programming commands..
>>
>> How do I create the source file and compile it? Is it under CL or is
>> it under CMD?
>>
>> Gil
>>
>> Jeff Crosby wrote:
>>[color=darkred]
>>> [email]dan@willcraft.com[/email] wrote:
>>>
>>>> We just got a new 515
>>>> In the past we could type "DP" and see all spool files (not D SPACE P)
>>>>
>>>> We can't type that command now, the vendor says that was specific to a
>>>> System36 environment.
>>>>
>>>> They tell us we now have to type "wrksplf select(*all)"
>>>>
>>>> I do not really want our users to start getting heavy on the CL.
>>>>
>>>> Is there a way I can do something so we can still type DP and have it
>>>> kick that off?
>>>
>>>
>>>
>>>
>>> We have a number of "shortcut" commands here. Below is an example of
>>> 1, the "W" command. If you type in "W P" (or just "W" since "P" is
>>> the default) you see your spool files. Key in "W W" to work with
>>> writers.
>>>
>>>
>>> /* Command processing program is QCMDEXC */
>>>
>>> CMD PROMPT('Various WRK Commands')
>>>
>>> PARM KWD(OPTION) TYPE(*CHAR) LEN(32) RSTD(*YES) +
>>> DFT(P) +
>>> SPCVAL((J 'WRKSBMJOB') +
>>> (P 'WRKSPLF') +
>>> (E '?WRKSPLFE') +
>>> (AJ 'WRKACTJOB') +
>>> (O '?WRKOUTQ') +
>>> (INV 'WRKOUTQ FPHOLD') +
>>> (MLB 'WRKMLBBRM') +
>>> (FP 'WRKOUTQ FP*') +
>>> (Z 'WRKOUTQ Z*') +
>>> (JQ '?WRKJOBQ QBATCH') +
>>> (JS '?WRKJOBJS') +
>>> (L '?WRKOBJLCK') +
>>> (SPLF '?WRKSPLF') +
>>> (U 'WRKUSRJOB *ALL *ACTIVE') +
>>> (UA 'WRKUSRJOB') +
>>> (FV 'WRKFAVCMD') +
>>> (ACT 'WRKSYSACT') +
>>> (W 'WRKWTR') +
>>> (WA 'WRKWTR *ALL')) +
>>> EXPR(*YES) PROMPT('Option')
>>> PARM KWD(LENGTH) TYPE(*DEC) LEN(15 5) CONSTANT(32)
>>>
>>>
>>>
>>> Another example, the "M" command.
>>>
>>> M: CMD PROMPT('Run DSPMSG Command')
>>> /* Command processing program is QCMDEXC */
>>>
>>> PARM KWD(OPTION) TYPE(*CHAR) LEN(32) RSTD(*YES) +
>>> DFT(M) +
>>> SPCVAL((M 'DSPMSG') +
>>> (L 'DSPMSG ACCESS') +
>>> (O 'DSPMSG ORDERS') +
>>> (S 'DSPMSG SPCITMORD') +
>>> (IXS 'WRKMSGQ IXS/*ALL') +
>>> (MM '?DSPMSG')) +
>>> EXPR(*YES) PROMPT('Option')
>>> PARM KWD(LENGTH) TYPE(*DEC) LEN(15 5) CONSTANT(32)
>>>
>>> Some of the options are unique to our environment. With a little
>>> imagination, the possibilities for this are almost endless. They can
>>> even be allowed for limited users so users can do things like display
>>> their messages from anywhere.
>>>
>>> This is not an original idea of mine, I got it from someone online at
>>> least 15 years ago. The time it has saved our company is nothing
>>> short of amazing.
>>>
>>> HTH.[/color][/color]
>
>
> Commands, so use CTRCMD. Remember, the PGM parm is QCMDEXC, like this:
>
> CRTCMD CMD(W) PGM(QCMDEXC)[/color]