How to create a TABULATE report that excludes C_TYPE and C_TRAN entries that are blank fields in the output?
SAMPLE code
COPY GSVSMF27
SELECT JOBNAME(TTINDCS)
SELECT TRANID(DIMS)
TAB DATE TIME USERID
TAB2 C_UTYPE ,
C_UTRAN ,
PROG USE
EACH 15 MINUTES
RANGE PROG USE 200+ DEFERRED
END
RUN
OUTPUT RESULT
USER CICS CICS PROG
DATE TIME ID UTYPE UTRAN USE
-------- ----- -------- -------- -------- --------
12/09/21 15.00 SAULOM
12/09/21 15.00 I002
12/09/21 15.00 CE3F
12/09/21 15.00 TXAM9
12/09/21 15.00 TXAL3
12/09/21 15.00 TAMMYN
12/09/21 15.00 TXBG1
12/09/21 15.00 TXAV4 1904
12/09/21 15.00 TXAV4 PARTMO PARTMO 272
12/09/21 15.00 TXAV4 PARTDI PARTDI 272
-------- -------- --------
12/09/21 15.00 TXAV4 SUMMARY 2448
Release : 15.0 and above
Component : Explore Report Writer for SYSVIEW/E
There is a particular rule about Report Writer's syntax parser when space/blank characters are involved.
Put an additional SELECT statement to filter out C_UTYPE fields that are blank, like this:
COPY GSVSMF27
SELECT JOBNAME(TTINDCS)
SELECT TRANID(DIMS)
SELECT C_UTYPE(¬'4040404040404040')
TAB DATE TIME...
The "not" symbol will subtract from the report.
The '4040404040404040' is just 8 space/blank EBCDIC characters represented in hex format.
There is no way to represent a space in Report Writer in a SELECT statement other than using hex.
When Report Writer's syntax parser sees a space, it assumes it's either the end of the line or the next parameter.
In this case, the space is desired and significant, so it is necessary to use something other than a character space to represent a space, so hex '40' is the answer.
Be careful when copy/pasting the "not" symbol.
In Report Writer, it's a "¬" (not) symbol, not a "^" (caret) symbol which is much more commonly used in other mainframe utilities.