If the date is written in the text file MDY order then use the MMDDYY informat instead of the DATE informat. I would still attach the DATE9. format (or perhaps the YYMMDD10. format) to the variable so that when you print the dates they are not in that ambiguous MDY order (many places in the world use DMY order and unless the day of the month is larger than 12 you cannot tell which is which from looking at the printout.
What did you see in the SAS log when it dumped line two to the log for you for the value of DATE and ENCOUNTER_NUMBER that it was complaining about?
It looks like perhaps ENCOUNTER_NUMBER is also not a number, despite its name. Define it as character and see what types of values you see.
Also take a close look at what you have in the file for encounter_number. You may need a custom informat, if there's stuff like N/A.
Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.