I have 1800 files in a directory. The file name is like out_cpty_XXXX. The "XXXX" vaires from file to file. I want to get the count of files with file name out_cpty_XXXX. How to get the count with just the partial file name?
Directory "A" has files like
out_cpty_123; out_cpty_456; out_cpty_789....upto 1800 files
out_pstn_123; out_pstn_456; out_pstn_789....upto 50000 files
Directory "B" also the same files like above
I want to compare out_cpt_123 from both directories. Likewise each file from directory A should be compared with the like files from directory B.
Any help would be appreciated.