I will be receiving data files in a Linux directory.
I need to validate that the file names follow the following pattern "NNN-YYYYMMDD-NNNNNNNNN.pdf" where
- NNN stands for numeric value (0-9).
- "YYYYMMDD" stands for valid date. YYYY is the year, MM is the month (between 1-12) and DD is the day of the month (can have values between 01 to 31 depending on the month).
- NNNNNNNN is a numeric number (i.e. only 0-9 allowed).
What utility (SED, AWK etc.) and how should I use to validate the file name.