If the CSV file has 4 digits for YEAR and you read it using your example INPUT statement then the values are just being stored as numbers not date values. SAS stores dates as the number of DAYS since 1960, not the number of YEARS since 0 which what it looks like your code is assuming the CSV has.
So there is no need to attach any format at all to YEAR. SAS will display integers such as 2,020 and 2,021 as four digits strings like 2020 and 2021 without any need for you to give it special instructions on how to display the values. If you did want to attach a format then probably 4. would be good although if you want them to display with the thousands separator you might use comma5. instead.
... View more