Sri h Kolusu wrote:
>>>Is there a DFSORT or ICETOOL statement where the output contains headers
>>>plus a line saying 'No selected records found' if nothing selected is found?
>It can be done , however I need a few more details.
First thing first, many thanks for offering help.
>1. How are you selecting the data? (using INCLUDE/OMIT COND or OUTFIL
>INCLUDE/OMIT ?)
I am mostly using ICETOOL with both these two sets of statements or only with
one, like this example with INCLUDE COND:
(PS - fields with @ are replaced by actual contents)
SORT FROM(INDD) TO(TEMP0003) USING(REST)
DISPLAY FROM(TEMP0003) LIST(PRINT3R) -
NOCC -
WIDTH(500) -
BETWEEN(2) -
TITLE('@PREFIX - @SYSTM: Active Ids') -
DATE(4MD/) -
TIME(24:) -
PAGE -
BLANK -
ON(NUM,N05) HEADER('NR') -
ON(10,8,CH) HEADER('User id') -
ON(79,20,CH) HEADER('User Name') -
ON(100,8,CH) HEADER('Dflt Group') -
ON(19,10,CH) HEADER('Created') -
ON(118,10,CH) HEADER('Last Used')
OCCUR FROM(TEMP0003) LIST(PRINT3T) -
NOCC -
WIDTH(500) -
ON(78,1,CH) HEADER('Active Ids') -
ON(VALCNT,N05) HEADER('Count')
//RESTCNTL DD *
SORT FIELDS=(10,8,CH,A)
INCLUDE COND=(5,4,CH,EQ,C'0200',AND,
54,4,CH,NE,C'YES ',AND,
118,10,CH,NE,C' ',AND,
118,10,CH,NE,19,10,CH,AND,
100,8,CH,EQ,C'@GROEP',AND,
10,3,CH,EQ,C'@PREFIX')
With these ICETOOL statements, when there is nothing I get this lame output:
********************************* Top of Data *****************
XYZ - SYSTEM: Active Ids 2017/05/31 13:37:55
NR User id User Name Dflt Group Created
------ -------- -------------------- ---------- ----------
Active Ids Count
---------- ------
******************************** Bottom of Data ***************
... resulting in unneeded queries from reviewers of these reports.
>2. What is the LRECL and RECFM of the dataset?
It should not matter, but output is generally LRECL=500 and RECFM=FB (see NOCC
in above example)
Input for this specific example is a RACF Unloaded DB. RECFM=VB, LRECL=4096.
I am also using SMF unloaded dataset from IRRADU00 (LRECL=12288, RECFM=VB) as
well other SMF data and other datasets.
>3. Does the header already exist in the input file and is it the first 2
>records in the file? or can this be generated?
No. I prefer raw data without headers as input, so I can add headers at a later
stage like this ICETOOL example above or simply omit headers for sending over
as a CSV file.
Many thanks again!
Groete / Greetings
Elardus Engelbrecht
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN