Skip to content

Instantly share code, notes, and snippets.

@berk76
Last active March 4, 2020 20:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save berk76/1e5af170bf455d562439f80de98fb1e2 to your computer and use it in GitHub Desktop.
Save berk76/1e5af170bf455d562439f80de98fb1e2 to your computer and use it in GitHub Desktop.
CL Commands

Short description of some important CL commands

Content

  1. Important special keys
  2. CL Commands
    1. Commands
    2. When you need more room on the command line
    3. Object (file) types
    4. Values
  3. Scheduler
  4. SEU Editor
  5. Programming
    1. Program Development Manager
    2. C Programming
    3. CL Programming
  6. Download report

Important special keys

F1 Online help
F3 Exit
F4 Prompt screen (entry screen whose fields prompt you for parameters)
F9 Retrives the previously entered commands
F12 Cancel
F13 User support and education menu
F16 Major commands (GO MAJOR)
F23 Set current menu as initial menu (see change in chgprf)
F24 More keys

CL Commands

CL commands usually starts with:

str... start
dsp... display
crt... create
wrk... work with
chg... change

Commands

Command Description
signoff logout
go <menu> go to menu
smdmsg send message
dspmsg display message
dltf delete file
rnmobj obj(oldname) objtype(*file) newobj(newname) rename object
cpyf copy file (F4 show parameters)
chgprf change profile
chgpwd change password
chgcurlib change current library
strschidx search indexer (help)
go support user support and education menu
stredu start education
dspkbdmap display keyboard map
go assist operational assistent
wrksysact cpu usage
dsplib list of files in library
dsplibl display your library list
dspfd list members in file
dsppmf display a file or file members contents
crtdupobj copy files or objects
cpysrcf copy file members
rnmobj rename files or objects
rnmm rename file members
dltf delete files
dltpgm delete pgm
rmvm delete file members
edtlibl edit your library list
crtlib create library
dltlib delete library
crtpf create physical file
crtsrcpf create source physical file
wrksplf work with print spooler
sndnetf send file
rcvnetf receive file
wrknetf work with net files
dspjob - 4 display spooled filesv
dspobjd display object details

When you need more room on the command line

call qcmd then F11

Object (file) types

*LIB Library
*FILE File
*CMD Command
*PGM Program

Values

*LIBL refers to library list
*PRINT printer

Scheduler

ADDJOBSCDE add job schedule entry
CHGJOBSCDE change job
WRKJOBSCDE list of jobs

SEU Editor

strseu run seu

Commands

i insert line
rp duplicate line
d (dd,dd) delete line
c (cc,cc,a|b) copy lines
m (mm,mm,a|b) move lines
find something search for
save [new member] saves changes

Programming

Program Development Manager

wrkmbrpdm listing files members

C Programming

strpdm Programming development manager
crtcmod Create C module
crtpgm Create PGM from module
crtpgm pgm(xberan/sesstest) module(xberan/sesstest) bnddir(qsnapi)
crtbndc Create Bound C program
crtbnddir Create binding directory (CRTBNDDIR BNDDIR(MYBNDDIR) MODULES (MOD1, MOD2))
updpgm Update PGM
crtsrvpgm Create SRVPGM
dspmod Display exports in module
rtvbndsrc Create binder language code which can be used as EXPORT param of CRTSRVPGM
wrkmsgd <id> Show message/error description

CL Programming

crtclpgm Create CL programm

Example

crtsrcpf xberan/qclsrc Create file
strseu xberan/qclsrc getobjdata Open SEU editor

PGM                                                       
                                                          
             DSPOBJD    OBJ(ESGR4OBJ/*ALL) OBJTYPE(*PGM) +
                          DETAIL(*FULL) OUTPUT(*OUTFILE) +
                          OUTFILE(XBERAN/OBJDOUT)         
                                                          
ENDPGM

crtclpgm getobjdata Compile program

Download report

generate report
wrksplf xberan
8 - for attributes

cpysplf + F4
Spooled file:
To Database File: SPOOLFILE
Job Name:
User:
Number:
Spooled File Number:
Control Character: *PRTCTL
ftp 10.0.1.51
get spoolfile.spoolfile
wrksplf xberan
4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment