TIP # 070
The Easiest and Coolest way to locate bad data is thru File-Aid's FIND command.
1.OPEN the file in FILE-AID (in either browse or edit mode)
2.XREF with COPYBOOK.
3.Use FMT mode
4.Then issue ,
F /field-name INVALID
F /field-number INVALID
The control will take you to the first invalid data record for the given field.
The FILE has 3 fields namely NAME,AGE,COUNTRY.
If you want to find the invalid data in the age field, then issue
F /2 INVALID
TIP # 071
We always face a s ituation such that when we have opened a File in FI LEAI
D Brows e mode but later wished it was EDI T Mode and vice ver sa. S o in
this s ituation, what we do is come out of the brows e mode and again open in
edit mode and vice ver sa. But ther e is a cool command available in FI LE-AI D
to help us in this type of s ituation.
I f u r in Brows e Mode and want to change it into EDI T Mode , in the Line
Command is sue
COMMAND = = > GO EDI T
I f u r in EDI T Mode and want to change it into BROWS E Mode , in the Line
Command is sue
COMMAND = = > GO BROWS E
TIP # 072
How to determine compile date of loadlib member ??
Use FILE-AID !!
1. Go to FILE-AID 3.1 option
2. In the Library Utility type in the loadlib dataset name
3. Type 'a' next to the member name
4. TDATE is compile date
TIP # 073
Whats the best way to count the number of records in a VSAM File?
1.Choose FILE-AID Option 3.8
2. At the prompt of ....ENTER NEXT FUNCTION OR END , enter TALLY
3. U will get the record count
4. Type END to exit.
TIP # 074
While working in MS Excel we have the option of “freeze Panes”. By this options we can freeze
some columns and have other columns scrolling. This feature is helpful in analysis when there
are lots of columns(fields) in a file.
In mainframe too, we have similar such facility thru File-Aid.
1.Open the file in File-Aid
2. use VFMT format
3. If you want to freeze columns(fields) 1,2,3, and 6 and have the rest as scrollable
issue command HOLD 1-3,6
TIP # 075
Can I issue FIND command to find values that are less than or greater than ‘certain value’ at
We can’t accomplish this task thru ISPF , but File -Aid provides us the facility to issue FIND
command with relational operators like EQ,NE,LT,GT,LE and GE.
FIND LT ‘2004’ 25 ALL
So if one wants to use relational operator along with FIND command, open the same dataset in
TIP # 076
Consider this situation. I am doing a verification on an output file. The output file has 200 fields.
I need to verify only 25th and 175th fields only.
I am using FILE-AID’s VFMT mode and for each record I am scrolling between 25 th and 175th
field. Is there any efficient way to handle this situation?
Some people might use HOLD to freeze 25th and 175th field , but still other fields are displayed ,
which is an annoyance.
Here is one better way:
In the VFMT mode, issue DISPLAY 25 175 ONLY
Only 25th and 175th fields will be displayed.
TIP # 077
At midnight I receive production call.
One job abended due to classic S0C7. Thru analysis I located the particular field which is a
COMP-3 and junk data is sitting in that field for some records.These bad records are not
contiguous but occuring randomly in the input file.
Now to save my head I have to delete all the records with bad data in that particular field and reexecute
the job quickly. Assume that input file has some 10 million records. How can I eliminate
the bad records in an efficient and a fast method?
Here is the approach:
Using the following FILE-AID option in batch mode
$$DD01 DROP IF=(field-position, field-length, NEP)
NEP means Not Equal to PACK
One can generalize and customize the below JCL to deal with similar type of ABENDS.
My input layout is:
05 NAME-FIELD PIC X(5).
05 AMOUNT-FIELD PIC 9(3) COMP-3.
My JCL to eliminate the bad records:
//STEP01 EXEC PGM=FILEAID
//SYSUDUMP DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSLIST DD SYSOUT=*
//SYSTOTAL DD SYSOUT=*
//DD01 DD DSN=MYID.CHECK.OUT,DISP=SHR
//DD01O DD DSN=MYID.CHECK.OUT,
//SYSIN DD *
$$DD01 DROP IF=(6,2,NEP)
This will drop the bad data records and retain only the good one.
TIP # 078
I want to do Fuzzy Comparison of files!!
My requirement is to compare 2 files of which for one certain field I can have + or - 1 value which should
be acceptable while comparing.
Thru FILE-AID COMPARE (OPTION 10), one can set percentage amount for numeric
fields that determines "close enough" matches. When the "Formatted Criteria" table
appears after the 2 files are specified, use the "T" line command. This brings up a
"Tolerance Value/Percentage Specification" panel where you can set a plus or minus
value for a numeric field.