As mentioned in the earlier posts, we can get the number of records in a file using a job. It can also be found using File-Aid. Use "Interactive" option in File-Aid and then give the name of the dataset on disk. Then it will ask to enter the function. Type TALLY and wait.It will give the record count.
Corrections welcome !