Displaying date in SAS I am trying to display a date in my result after running the below program in SAS. It runs properly but in the sas data table under DOB column I don't get anything except a period . 

Below is my code what am I doing wrong?

data sample; 
Input ID name $ Dob;
Format DOB mmddyy10. ; 
datalines;
1 abc 22jan1996
2 xyz 25aug1996
;
run;
Proc print data = sample;
run; 


Also I would like to know what does a period means at the end of this line before the semicolon:

Format DOB mmddyy10. ;
Try the following:

data sample; 
Input ID name $ Dob;
informat DOB date9. ; 
format DOB mmddyy10. ; 
datalines;
1 abc 22jan1996
2 xyz 25aug1996
;
run;
Proc print data = sample;
run; 


I have added the informat line. The problem with the original code is that you have not told SAS what is the format that DOB will come in. In this case: 22jan1996 is of date9. format, so I added the informat telling SAS that the data will come in this way.

The format DOB line tells SAS to display the data as mmddyy10. which makes 22jan1996 look like 01/22/1996.

Lastly, the . before the ; in the format/informat lines specifies that it is a format type. There are character formats: $8. or numeric formats Best12. etc...