how to view the logs of all command you entered for the review purposes?

20 pts.
Tags:
AS/400
AS/400 commands
AS/400 logs
how to view the logs of all command you entered for the review purposes?

Answer Wiki

Thanks. We'll let you know when a new response is added.

<pre> H DftActGrp(*No) Actgrp(*Caller) BndDir(‘QC2LE’)
FCmdLogD cf e Workstn Sfile(Data:Rrn) InfDs(DsInf)
F IndDs(Ind)
FCmdLogF if a e Disk UsrOpn ExtMbr(UserId)
F Rename(CmdLogf:RCmdLogF)
// Define command keys
D DsInf Ds
D FKEY 1 Overlay(DsInf:369)
D F03 c Const(X’33′)
D F05 c Const(X’35′)
D F06 c Const(X’36′)
D F07 c Const(X’37′)
D F12 c Const(X’3C’)
D F21 c Const(X’B9′)

// Name screen indicators
D Ind Ds Qualified
D SflDsp n Overlay(Ind:1)
D ReverseImage n Overlay(Ind:20)
D ErrMsg n Overlay(Ind:30)
D System Pr 10i 0 ExtProc(‘system’)
D I_Cmd * Value Options(*String)
D RtnCode s 10i 0
//
D Qmhrtvm Pr ExtPgm(‘QMHRTVM’) RETRIEVE MESSAGE
D 256 message retrieved
D 10i 0 length of message
D 8 Const requested format
D 7 msg identifier
D 20 Const Qualified msgf name
D 128 Const replacement data
D 10i 0 Const len of replace data
D 10 Const Substitution char
D 10 Const format control char
Db Like(vApiErrDs)
D Qmhsndpm Pr ExtPgm(‘QMHSNDPM’) SEND MESSAGES
D 7 Const ID
D 20 Const FILE
D 73 Const TEXT
D 10i 0 Const LENGTH
D 10 Const TYPE
D 10 Const QUEUE
D 10i 0 Const STACK ENTRY
D 4 Const KEY
Db Like(vApiErrDs)
// ————————————————————-
D Qcmdchk Pr ExtPgm(‘QCMDCHK’)
D 500a
D 15p 5 Const
// ————————————————————-
D Quscmdln Pr ExtPgm(‘QUSCMDLN’)
//—————————————————————-
// Error return code parm for APIs.
//—————————————————————-
D vApiErrDs Ds
D vbytpv 10i 0 Inz(%Size(vApiErrDs)) bytes Provided
D vbytav 10i 0 Inz(0) bytes returned
D vmsgid 7a error msgid
D vresvd 1a reserved
D vrpldta 50a replacement data
D Excp_MsgId s 7a Import(‘_EXCP_MSGID’)
//
/if defined(QMHLJOBL_H_DEFINED)
/endif
/define QMHLJOBL_H_DEFINED

D QMHLJOBL Pr ExtPgm(‘QMHLJOBL’)
D UsrSpc 20A Const
D Format 8A Const
D MsgSel 32767A Const Options(*Varsize)
D MsgSelSize 10i 0 Const
D SelFormat 8a Const
D ErrorCode 32767A Const

D QMHLJOBL_QualJob_T…
D Ds Qualified
D Based(Template)
D Name 10a
D User 10a
D Nbr 6a

D JSLT0100_T Ds Qualified
D Based(Template)
D MaxMsgs 10i 0
D Direction 10a
D Job LikeDs(QMHLJOBL_QualJob_T)
D IntJobId 16a
D StrMsgKey 4a
D MaxMsgLen 10i 0
D MaxMsgHlp 10i 0
D FieldIdOff 10i 0
D FieldCount 10i 0
D MsgQOff 10i 0
D MsgQLen 10i 0
D RtnFld 10i 0 Dim(50)
D MsgQName 4096a

D QMHLJOBL_Header_T…
D Ds Qualified
D Based(Template)
D UsrSpc 20a
D StrMsgKey 4a
D EndMsgKey 4a
D QualJob LikeDs(QMHLJOBL_QualJob_T)
D 2a
D CCSID 10i 0

D LJOB0100_T Ds Based(Template)
D Qualified
D OffsetToNext 10i 0
D OffsetToFlds 10i 0
D NumFldsRetrn 10i 0
D MsgSeverity 10i 0
D MsgId 7a
D MsgType 2a
D MsgKey 4a
D MsgFileName 10a
D msgFileLib 10a
D DateSent 7a
D TimeSent 6a
D Microsec 6a

D LJOB0100_Field_T…
D Ds Based(Template)
D Qualified
D OffsetToNext 10i 0
D LengthOfFlds 10i 0
D IdentifierF 10i 0
D TypeOfData 1a
D StatOfdata 1a
D Reserved 14a
D LengthOfData 10i 0
D LogData 32767a
/if defined(USRSPC_H_DEFINED)
/endif
/define USRSPC_H_DEFINED

*

* USRSPC_H is the /COPY member containing definitions for use
* with user spaces.
*

*—————————————————————
* QUSCRTUS(): Create User Space
*
* usrspc = (input) Qualified user space name
* pos 1-10 = object name
* 11-20 = library name
* extattr = (input) attribute displayed in WRKOBJ panels
* size = (input) initial size of user space
* value = (input) initial value of bytes in user space
* (use x’00′ for best performance)
* publicAuth = (input) authority that *PUBLIC gets to space
* Text = (input) Text description of user space
* — optional group 1 —
* Replace = (input/optional) Replace if exists? (*YES/*NO)
* ErrorCode = (i/o) standard API error code
* — optional group 2 —
* Domain = (input/optional) Domain (*DEFAULT/*SYSTEM/*USER)
* — optional group 3 —
* XferSizeReq = (input/optional) number of pages of storage to
* transfer on each request
* 0 = use the default value
* 1-32 = number of pages
* OptSpcAlign = (input/optional) Use optimimum space alignment?
* 0 = do not choose optimum (default)
* 1 = choose optimum alignment
*—————————————————————
D QUSCRTUS Pr ExtPgm(‘QUSCRTUS’)
D usrspc 20A Const
D extattr 10A Const
D size 10i 0 Const
D value 1A Const
D publicAuth 10A Const
D Text 50A Const
D Replace 10A Const Options(*Nopass)
D ErrorCode 32767A Options(*Varsize:*Nopass)
D Domain 10A Const Options(*Nopass)
D XferSizeReq 10I 0 Const Options(*Nopass)
D OptSpcAlign 1A Const Options(*Nopass)

*—————————————————————
* QUSPTRUS(): Retrieve Pointer to User Space
*
* usrspc = (input) Qualified user space name
* pos 1-10 = object name
* 11-20 = library name
* pointer = (output) pointer retrieved
* — optional group 1 —
* ErrorCode = (i/o) standard API error code
*—————————————————————
D QUSPTRUS Pr ExtPgm(‘QUSPTRUS’)
D usrspc 20A Const
D pointer *
D ErrorCode 32767A Options(*Varsize:*Nopass)

*—————————————————————
* QUSDLTUS(): Delete User Space
*
* usrspc = (input) Qualified user space name
* pos 1-10 = object name
* 11-20 = library name
* — optional group 1 —
* ErrorCode = (i/o) standard API error code
*—————————————————————
D QUSDLTUS Pr ExtPgm(‘QUSDLTUS’)
D usrspc 20A Const
D ErrorCode 32767A Options(*Varsize)

*—————————————————————
* QUSCHGUS(): Change User Space Contents
*
* NOTE: This is only included for completeness. For best
* performance, and simplest coding, please use pointer
* access to change a user space.
*
* usrspc = (input) Qualified user space name
* pos 1-10 = object name
* 11-20 = library name
* start = (input) starting position within space
* len = (input) length of data to change
* data = (input) new data to assign
* ForceAux = (input/optional) force changes to aux storage
* (i.e. make data write to disk immediately
* instead of caching in memory)
* 0 = do not force (best performance)
* 1 = force asynch (medium performance)
* 2 = force synch (worst performance)
* — optional group 1 —
* ErrorCode = (i/o) standard API error code
*—————————————————————
D QUSCHGUS Pr ExtPgm(‘QUSCHGUS’)
D usrspc 20A Const
D Start 10I 0 Const
D Len 10I 0 Const
D Data 65535A Const Options(*Varsize)
D ForceAux 1A Const
D ErrorCode 32767A Options(*Varsize:*Nopass)

*—————————————————————
* QUSCHGUS(): Retrieve User Space Contents
*
* NOTE: This is only included for completeness. For best
* performance and simplest coding, please use pointer
* access to read a user space.
*
* usrspc = (input) Qualified user space name
* start = (input) starting position in the user space
* len = (input) length of data to read
* RcvVar = (output) variable to receive data
* — optional group 1 —
* ErrorCode = (i/o) standard API error code
*—————————————————————
D QUSRTVUS Pr ExtPgm(‘QUSRTVUS’)
D usrspc 20A Const
D Start 10I 0 Const
D Len 10I 0 Const
D RcvVar 32767A Options(*Varsize)
D ErrorCode 32767A Options(*Varsize:*Nopass)

*—————————————————————
* QUSCUSAT(): Change user space attributes (“cuss at”)
*
* rtnlib = (output) annoying “returned library” parameter
* Note: I recommend that you do not use this.
* Use QUSRUSAT to get the library, if needed
* so I have this defined as Const so you don
* have to always create an unused temporary
* variable every time you call this API.
* You can disable this behavior with
* /define NO_RTNLIB_HACK if you like.
* usrspc = (input) Qualified user space name
* attr = (input) attribute list (see Qus_UsrSpc_Attr_LIst_T)
* to change in user space
* ErrorCode = (i/o) standard API error code
*—————————————————————
D QUSCUSAT Pr ExtPgm(‘QUSCUSAT’)
D rtnlib 10A
/if not defined(NO_RTNLIB_HACK)
D Const
/endif
D usrspc 20A Const
D attr 480A Const Options(*Varsize)
D ErrorCode 32767A Options(*Varsize)

*
* Possible key values for QUSCUSAT:
*
D QUS_ATTR_SPACE_SIZE…
D C 1
D QUS_ATTR_INITIAL_VALUE…
D C 2
D QUS_ATTR_AUTO_EXTEND…
D C 3
D QUS_ATTR_XFER_SIZE_REQ…
D C 4

*
* The “Proper” way to call the QUSCUSAT API is to set all of
* the needed attributes in an array of data structures. However
* this requires V5R2, and even in later releases is more awkward
* than using flat DS. Granted, with the flat DS you have to
* call the API repeatedly (once for each key) but in my experience
* it’s unusual to need to change more than one attribute anyway.
*
* Consequently, if you want the “Proper” apProach (with a nested
* array) you can define USE_NESTED_STRUCTURES. But, by default
* I have the “flat” version defined.
*
/if defined(USE_NESTED_STRUCTURES)

D Qus_UsrSpc_Attr_List_T…
D Ds Qualified
D based(Template)
D NbrKeys 10I 0
D Key 10I 0
D Length 10I 0
D Value
D IntValue 10I 0 Overlay(Value)
D CharValue 1A Overlay(Value)

/endif

*
* This is a “short cut” to save me time. 99% of the time that
* I use QUSCAT, I use it for “auto-extend” so I’ve Predefined
* the auto-extend values in their own DS.
*
D Qus_Auto_Extend…
D Ds Qualified
D NbrKeys 10I 0 Inz(1)
D Key 10I 0 Inz(QUS_ATTR_AUTO_EXTEND)
D Length 10I 0 Inz(%size(Qus_Auto_Extend.Value))
D Value 1A Inz(’1′)

*—————————————————————
* QUSRUSAT(): Retrieve User Space Attributes
*
* RcvVar = (output) attributes retrieved (data structure thats
* in SPCA0100 format… see the
* Qus_SPCA0100_T ds, below)
* RcvVarLen = (input) size of receiver variable
* format = (input) format of attributes (SPCA0100)
* usrspc = (input) user space to retrieve the attributes of
* ErrorCode = (i/o) standard API error code
*—————————————————————
D QUSRUSAT Pr ExtPgm(‘QUSCUSAT’)
D RcvVar like(Qus_SPCA0100_T)
D RcvVarLen 10i 0 Const
D format 8A Const
D usrspc 20A Const
D ErrorCode 32767A Options(*Varsize)

*
* Data structure to contain the returned definitions
*
D Qus_SPCA0100_T…
D Ds Qualified
D based(Template)
D BytesRtn 10I 0
D BytesAvail 10I 0
D Size 10I 0
D AutoExtend 1A
D InitValue 1A
D Library 10A

*—————————————————————
* Qus_Generic_Header_0100_T: Structure of the generic header
* used by the i5/OS list APIs.
*
* 99% of the time, I only use the Offset, Count & Size fields
* so I have these defined with simple, short names to
* simplify coding
*—————————————————————
D Qus_Generic_Header_0100_T…
D Ds Qualified
D based(Template)
D User_Area 64A
D GenHdrSize 10I 0
D Release 4A
D Format 8A
D API_Used 10A
D TimeCreated 13A
D InfoStatus 1A
D SpaceSize 10i 0
D InputOffset 10i 0
D InputSize 10i 0
D HeaderOffset 10i 0
D HeaderSize 10i 0
D ListOffset 10i 0
D Offset 10i 0 Overlay(ListOffset)
D ListSize 10i 0
D EntryCount 10i 0
D Count 10i 0 Overlay(EntryCount)
D EntrySize 10i 0
D Size 10i 0 Overlay(EntrySize)
D EntryCCSID 10i 0
D CountryID 2A
D LanguageID 3A
D Subset 1A
D 42A

*—————————————————————
* Qus_Generic_Header_0300_T: Same as Qus_Generic_Header_0100_T
* except for 1 additional field
* typically used with ILE versions
* of the list APIs.
*—————————————————————
D Qus_Generic_Header_0300_T…
D Ds Qualified
D based(Template)
D User_Area 64A
D GenHdrSize 10I 0
D Release 4A
D Format 8A
D API_Used 10A
D TimeCreated 13A
D InfoStatus 1A
D SpaceSize 10i 0
D InputOffset 10i 0
D InputSize 10i 0
D HeaderOffset 10i 0
D HeaderSize 10i 0
D ListOffset 10i 0
D Offset 10i 0 Overlay(ListOffset)
D ListSize 10i 0
D EntryCount 10i 0
D Count 10i 0 Overlay(EntryCount)
D EntrySize 10i 0
D Size 10i 0 Overlay(EntrySize)
D EntryCCSID 10i 0
D CountryID 2A
D LanguageID 3A
D Subset 1A
D 42A
D Entry_Point 256A
D 128A
D UsrSpc s 20 Inz(‘LOGCMDS QTEMP ‘)
D Rrn s 5u 0 Inz(0)
D ForCounter s 5u 0
D mMsgRtv Ds Inz
D mMsgRtvLen 9 12i 0 length msg retrie
D mMsgMessage 25 256 message retrieved
D mMsgLen s 10i 0 Inz(%Len(mMsgRtv)) length of message
D CmdList s 500 Dim(1000)
D CmdCounter s 5u 0 Inz(0)
D PgmInd Ds
D IsExitPgm n Overlay(PgmInd:1) Inz(*Off)
D RestoreCmds n Overlay(PgmInd:2) Inz(*Off)

D Sel Ds LikeDs(JSLT0100_T)
D Header Ds LikeDs(Qus_Generic_Header_0100_T)
D Based(p_Header)
D ApiHdr Ds LikeDs(QMHLJOBL_Header_T)
D Based(p_ApiHdr)
D Entry Ds LikeDs(LJOB0100_T)
D Based(p_Entry)
D Field Ds LikeDs(LJOB0100_Field_T)
D Based(p_Field)

D x s 10i 0

D ErrorCode Ds Qualified
D BytesProv 10i 0 Inz(0)
D BytesAvail 10i 0 Inz(0)
D UserId s 10a Inz(*USER)
IRCmdLogF
I CmdLogF CmdLogR
/Free

//
// Delete user space if it exists (ignore errors)
//
ErrorCode.BytesProv = %Size(ErrorCode);
QUSDLTUS( UsrSpc: ErrorCode );
//
// Create new user space to receive output
// and set pointer to that space
//
QUSCRTUS( UsrSpc
: ‘JOBLOG ‘
: 100 * 1024
: x’00′
: ‘*ALL’
: ‘List of Job Log Messages’ );

QUSPTRUS( UsrSpc: p_Header );

Sel.MaxMsgs = -1;
Sel.Direction = ‘*PRV’;
Sel.Job = ‘*’;
Sel.StrMsgKey = *Allx’FF’;
Sel.MaxMsgLen = 500;
Sel.MaxMsgHlp = 100;
Sel.FieldCount = 1;
Sel.RtnFld(1) = 301; // msgs w/replacement data
Sel.MsgQName = ‘*’;
Sel.MsgQLen = %Len(%Trimr(Sel.MsgQName));
Sel.FieldIdOff = %Addr(Sel.RtnFld) – %Addr(Sel);
Sel.MsgQOff = %Addr(Sel.MsgQName) – %Addr(Sel);

ErrorCode.BytesProv = 0;

// ———————————————————–
// Set looping subroutine so user can refresh screen
// ———————————————————–
Dou IsExitPgm;
Exsr srRefreshScreen;
EndDo;
// Delete User Space
QUSDLTUS( UsrSpc: ErrorCode );
// Send completion message
Callp QmhSndPm(
‘ ‘:’ ‘:
‘Command retrieval – completed’:
73:’*INFO ‘:’*CTLBDY ‘: 1:’ ‘:
vApiErrDs);
*Inlr = *On;
Return;

// ———————————————————–
// call api to load job log into user space.
BegSr srRefreshScreen;

QMHLJOBL( UsrSpc
: ‘LJOB0100′
: Sel
: %Size(Sel)
: ‘JSLT0100′
: ErrorCode );
// Process elements
p_Entry = p_Header + Header.Offset;
For ForCounter=1 to Header.Count;

If Entry.MsgType = ’08′ or Entry.MsgType=’10′;
p_Field = p_Header + Entry.OffsetToFlDs;

If %Subst(Field.LogData:1:1)>’ ‘ and
%Subst(Field.LogData:1:2)<>’/*’ and
%Subst(Field.LogData:1:6)<>’cmdlog’ and
%Subst(Field.LogData:1:6)<>’CMDLOG’ and
%Subst(Field.LogData:1:6)<>’ENDRQS’ and
%Subst(Field.LogData:1:6)<>’endrqs’;
FullCmd=%Subst(Field.LogData:1:
Field.LengthOfData);

If CmdCounter=0 or
%Lookup(FullCmd:CmdList:1:CmdCounter)=0;
CmdCounter = CmdCounter + 1;
CmdList(CmdCounter) = FullCmd;
Callp(e) Qcmdchk(FullCmd:%Len(%Trimr(FullCmd)));
If Not %Error;
Cmdmsg73=FullCmd;
Rrn=Rrn+1;
Ind.ReverseImage=*Off; // reverse image
Write Data;
EndIf;
EndIf;
EndIf;
EndIf;
p_Entry = p_Header + Entry.OffSetToNext;
EndFor;
If RestoreCmds;
Open CmdLogF;
Read RCmdlogF;
Dow Not %Eof;
If %Lookup(CmdLogR:CmdList:1:CmdCounter)=0;
CmdCounter = CmdCounter + 1;
CmdList(CmdCounter) = CmdLogR;
Cmdmsg73=CmdLogR;
FullCmd=CmdLogR;
Rrn=Rrn+1;
Write Data;
EndIf;
Read RCmdlogF;
EndDo;
Close CmdlogF;
EndIf;

// allow the user to make a selection from subfile.
S1recnum=1;
Ind.SflDsp = (Rrn > 0);
Ind.SflDspctl = *On;
Dow not (Fkey=f03);
Write Contrl;
Exfmt Keys;
If
Fkey=f05; // refresh
Ind.SflDsp=*Off;
Ind.SflDspctl=*Off;
Clear Errmsg;
Ind.ErrMsg=*Off;
Rrn=0;
Write Contrl;
CmdCounter=0;
IsExitPgm=*Off;
Leavesr;
ElseIf
Fkey=f06; // Save Log Info
FullCmd = ‘CHKOBJ OBJ(QGPL/CMDLOGF) OBJTYPE(*FILE) MBR(‘
+%Trim(UserId) + ‘)’;
RtnCode = system(FullCmd);
If RtnCode <> 0;
FullCmd = ‘ADDPFM FILE(QGPL/CMDLOGF) MBR(‘
+%Trim(UserId) + ‘)’;
Callp(e) Qcmdchk(FullCmd:%Len(%Trimr(FullCmd)));
If Not %Error;
RtnCode = system(FullCmd);
EndIf;
Else;
FullCmd = ‘CLRPFM FILE(QGPL/CMDLOGF) MBR(‘
+%Trim(UserId) + ‘)’;
Callp(e) Qcmdchk(FullCmd:%Len(%Trimr(FullCmd)));
If Not %Error;
RtnCode = system(FullCmd);
EndIf;
EndIf;
Open CmdLogF;
For ForCounter=1 to CmdCounter-1;
CmdlogR = CmdList(ForCounter);
Write RCmdlogf;
EndFor;
Close CmdLogF;
Leavesr;
ElseIf
Fkey=f07; // Restore Log Info
Open CmdLogF;
Read RCmdlogF;
Dow Not %Eof;
If %Lookup(CmdLogR:CmdList:1:CmdCounter)=0;
CmdCounter = CmdCounter + 1;
CmdList(CmdCounter) = CmdLogR;
Cmdmsg73=CmdLogR;
FullCmd=CmdLogR;
Rrn=Rrn+1;
Write Data;
EndIf;
Read RCmdlogF;
EndDo;
Ind.SflDsp = (Rrn > 0);
RestoreCmds=*On;
Close CmdlogF;

ElseIf
Fkey=f21; // command line
Callp(e) QUSCMDLN();

ElseIf
Ind.SflDsp=*Off
or Fkey=f03
or Fkey=f12;
IsExitPgm=*On;
Leavesr;

// Find the record in the subfile the user has selected.
Else;
Clear Errmsg;
Ind.ErrMsg=*Off;

Readc Data;
Dow not %Eof;
EXCP_MSGID = ‘ ‘;
Ind.ReverseImage=*Off; // reverse image

If Options= ’1′;
Callp System(FullCMD);
EndIf;
If Options= ’2′;
Callp System(‘?’+FullCMD);
EndIf;
If EXCP_MSGID>*Blanks; //error occurred
Ind.ReverseImage=*On; //reverse image subfile record
Ind.ErrMsg=*On; //error message

// call retrieve message API to pull in message text
Callp QMHRTVM(
mMsgRtv :
mMsgLen :
‘RTVM0100′:
EXCP_MSGID:
‘QCPFMSG *LIBL’:
‘ ‘:
0:
‘*YES ‘:
‘*NO ‘:
vApiErrDs);
// load error message
Errmsg = EXCP_MSGID +’: ‘ +
%Subst(mMsgMessage:1:mMsgRtvLen);
EndIf;

// Update subfile to reflect selected change.
Clear Options;
S1recnum = Rrn;
Update Data;

Readc Data;
EndDo;
EndIf;
EndDo;
EnDsr;
/End-Free

A*%%TS SD 20090120 152324 KOZLOWSJ REL-V5R2M0 5722-WDS
A*%%EC
A DSPSIZ(24 80 *DS3)
A CF01
A CF02
A CA03
A CF04
A CA05
A CA06
A CF07
A CF08
A CF09
A CF10
A CF11
A CA12
A CA21
A INDARA
A R DATA SFL
A FULLCMD 500A H
A OPTIONS 1A B 4 2
A CMDMSG73 73 O 4 4
A 20 DSPATR(RI)
A*—————————————————————-
A R CONTRL SFLCTL(DATA)
A*%%TS SD 20081205 144210 KOZLOWSJ REL-V5R2M0 5722-WDS
A SFLSIZ(0072)
A SFLPAG(0018)
A 01 SFLDSP
A 02 SFLDSPCTL
A N02 SFLCLR
A N04 SFLEND(*MORE)
A S1RECNUM 4S 0H SFLRCDNBR(CURSOR)
A 1 3′CMDLOG’
A COLOR(BLU)
A 1 22′Previously Executed Commands’
A DSPATR(HI)
A 1 62′JJK’
A COLOR(BLU)
A 1 72DATE
A EDTWRD(’0 / / ‘)
A COLOR(BLU)
A 2 2′Type Options, Press Eenter’
A COLOR(BLU)
A 2 72SYSNAME
A COLOR(BLU)
A 3 4’1=Run ‘
A COLOR(BLU)
A 3 14’2=Prompt’
A COLOR(BLU)
A*—————————————————————-
A R KEYS
A*%%TS SD 20090120 152324 KOZLOWSJ REL-V5R2M0 5722-WDS
A BLINK
A OVERLAY
A 23 2′F3=Exit’
A COLOR(BLU)
A 23 11′F5=Refresh’
A COLOR(BLU)
A 23 23′F6=Save Cmds’
A COLOR(BLU)
A 23 37′F7=Restore Cmds’
A COLOR(BLU)
A 23 54′F21=Command Line’
A COLOR(BLU)
A 23 71′F12=Cancel’
A COLOR(BLU)
A 30 ERRMSG 73A O 24 4DSPATR(RI)

CMD PROMPT(‘Previously Executed Commands’)

File: CMDLOGF
Libr: QGPL Mbr : CMDLOGF Fmt: CMDLOGF
Seq Pg K Field T Len Dl Fd Dd From To
5 1 CMDLOGF A 256 256 1 256
2 CMDLOGF#01 A 130 130 127 256
2 CMDLOGF#02 A 4 4 253 256</pre>

Discuss This Question: 4  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • TomLiotta
    ...logs of all command you entered... Do you only want to see the commands "you" entered in your current job? Do you want to see all commands you ever entered in any job? Do you want to see all commands entered by anybody? Tom
    125,585 pointsBadges:
    report
  • iiiiiiiiiiiii
    use DSPJOBLOG command to see what are all the commands you have used in the current job.
    335 pointsBadges:
    report
  • Lovemyi
    If you want to see the commands used by others then you either have to view all their joblogs or use a product such as AuthorityBroker from POWERTECH that allows users to take over more high profile user ids and then tracks what was done during that time. This tracks why it was done (Narrative line) as well as the commands that were run after taking over a more powerfull ID. The entries are pulled from the audit journal so make sure you run the reports often before the journals are removed or your data will be gone. Great auditing tool if you catch the transaction on a regular basis. Lovemyi
    2,310 pointsBadges:
    report
  • TomLiotta
    For basic review or for retrieval and execution, CALL QCMD and press <F10>.Assuming that your job has been logging the commands, they all show up and are available for recall or review. Of course, if your job isn't logging your commands, they won't be in your job log. Make sure your job is set for LOG(3 nn xxxxxx) at the least for logging Level. Tom
    125,585 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following